File tree Expand file tree Collapse file tree 1 file changed +5
-4
lines changed
Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -27,6 +27,7 @@ func (r PackageMakeCommandStubs) ServiceProvider() string {
2727 content := `package DummyName
2828
2929import (
30+ "github.com/goravel/framework/contracts/binding"
3031 "github.com/goravel/framework/contracts/foundation"
3132)
3233
@@ -149,13 +150,13 @@ import (
149150func main() {
150151 packages.Setup(os.Args).
151152 Install(
152- modify.File (path.Config("app.go")).
153+ modify.GoFile (path.Config("app.go")).
153154 Find(match.Imports()).Modify(modify.AddImport(packages.GetModulePath())).
154- Find(match.Providers()).Modify(modify.AddProvider ("&DummyName.ServiceProvider{}")),
155+ Find(match.Providers()).Modify(modify.Register ("&DummyName.ServiceProvider{}")),
155156 ).
156157 Uninstall(
157- modify.File (path.Config("app.go")).
158- Find(match.Providers()).Modify(modify.RemoveProvider ("&DummyName.ServiceProvider{}")).
158+ modify.GoFile (path.Config("app.go")).
159+ Find(match.Providers()).Modify(modify.Unregister ("&DummyName.ServiceProvider{}")).
159160 Find(match.Imports()).Modify(modify.RemoveImport(packages.GetModulePath())),
160161 ).
161162 Execute()
You can’t perform that action at this time.
0 commit comments