@@ -66,7 +66,7 @@ discard block |
||
66 | 66 | $path = $this->app['config']->get('modules.stubs.path') ?? __DIR__.'/Commands/stubs'; |
67 | 67 | Stub::setBasePath($path); |
68 | 68 | |
69 | - $this->app->booted(function ($app) { |
|
69 | + $this->app->booted(function($app) { |
|
70 | 70 | /** @var RepositoryInterface $moduleRepository */ |
71 | 71 | $moduleRepository = $app[RepositoryInterface::class]; |
72 | 72 | if ($moduleRepository->config('stubs.enabled') === true) { |
@@ -80,12 +80,12 @@ discard block |
||
80 | 80 | */ |
81 | 81 | protected function registerServices() |
82 | 82 | { |
83 | - $this->app->singleton(Contracts\RepositoryInterface::class, function ($app) { |
|
83 | + $this->app->singleton(Contracts\RepositoryInterface::class, function($app) { |
|
84 | 84 | $path = $app['config']->get('modules.paths.modules'); |
85 | 85 | |
86 | 86 | return new Laravel\LaravelFileRepository($app, $path); |
87 | 87 | }); |
88 | - $this->app->singleton(Contracts\ActivatorInterface::class, function ($app) { |
|
88 | + $this->app->singleton(Contracts\ActivatorInterface::class, function($app) { |
|
89 | 89 | $activator = $app['config']->get('modules.activator'); |
90 | 90 | $class = $app['config']->get('modules.activators.'.$activator)['class']; |
91 | 91 | |
@@ -100,14 +100,14 @@ discard block |
||
100 | 100 | |
101 | 101 | protected function registerMigrations(): void |
102 | 102 | { |
103 | - if (! $this->app['config']->get('modules.auto-discover.migrations', true)) { |
|
103 | + if (!$this->app['config']->get('modules.auto-discover.migrations', true)) { |
|
104 | 104 | return; |
105 | 105 | } |
106 | 106 | |
107 | - $this->app->resolving(Migrator::class, function (Migrator $migrator) { |
|
107 | + $this->app->resolving(Migrator::class, function(Migrator $migrator) { |
|
108 | 108 | $migration_path = $this->app['config']->get('modules.paths.generator.migration.path'); |
109 | 109 | collect(\Nwidart\Modules\Facades\Module::allEnabled()) |
110 | - ->each(function (\Nwidart\Modules\Laravel\Module $module) use ($migration_path, $migrator) { |
|
110 | + ->each(function(\Nwidart\Modules\Laravel\Module $module) use ($migration_path, $migrator) { |
|
111 | 111 | $migrator->path($module->getExtraPath($migration_path)); |
112 | 112 | }); |
113 | 113 | }); |
@@ -115,16 +115,16 @@ discard block |
||
115 | 115 | |
116 | 116 | protected function registerTranslations(): void |
117 | 117 | { |
118 | - if (! $this->app['config']->get('modules.auto-discover.translations', true)) { |
|
118 | + if (!$this->app['config']->get('modules.auto-discover.translations', true)) { |
|
119 | 119 | return; |
120 | 120 | } |
121 | - $this->callAfterResolving('translator', function (TranslatorContract $translator) { |
|
122 | - if (! $translator instanceof Translator) { |
|
121 | + $this->callAfterResolving('translator', function(TranslatorContract $translator) { |
|
122 | + if (!$translator instanceof Translator) { |
|
123 | 123 | return; |
124 | 124 | } |
125 | 125 | |
126 | 126 | collect(\Nwidart\Modules\Facades\Module::allEnabled()) |
127 | - ->each(function (\Nwidart\Modules\Laravel\Module $module) use ($translator) { |
|
127 | + ->each(function(\Nwidart\Modules\Laravel\Module $module) use ($translator) { |
|
128 | 128 | $path = $module->getExtraPath($this->app['config']->get('modules.paths.generator.lang.path')); |
129 | 129 | $translator->addNamespace($module->getLowerName(), $path); |
130 | 130 | $translator->addJsonPath($path); |