@@ -80,7 +80,7 @@ |
||
80 | 80 | |
81 | 81 | return $generator->file($path)->template($this->getStub(), [ |
82 | 82 | 'namespace' => $namespace, |
83 | - 'root_namespace' => $this->getAppNamespace(), // use App\Http\Requests\Request |
|
83 | + 'root_namespace' => $this->getAppNamespace(), // use App\Http\Requests\Request |
|
84 | 84 | 'class' => $class, |
85 | 85 | ]); |
86 | 86 | } |
@@ -67,12 +67,12 @@ discard block |
||
67 | 67 | { |
68 | 68 | foreach ($commands as $name => $class) { |
69 | 69 | if ($this->app->bound($name)) { |
70 | - $this->app->extend($name, function ($instance, $app) use ($class) { |
|
70 | + $this->app->extend($name, function($instance, $app) use ($class) { |
|
71 | 71 | return $app->build($class); |
72 | 72 | }); |
73 | 73 | } |
74 | 74 | else { |
75 | - $this->app->singleton($name, function ($app) use ($class) { |
|
75 | + $this->app->singleton($name, function($app) use ($class) { |
|
76 | 76 | return $app->build($class); |
77 | 77 | }); |
78 | 78 | } |
@@ -87,7 +87,7 @@ discard block |
||
87 | 87 | protected function silentLegacyCommands(array $commands) |
88 | 88 | { |
89 | 89 | foreach ($commands as $name => $class) { |
90 | - $this->app->extend($name, function ($instance, $app) use ($class) { |
|
90 | + $this->app->extend($name, function($instance, $app) use ($class) { |
|
91 | 91 | return $app->build($class); |
92 | 92 | }); |
93 | 93 | } |
@@ -70,8 +70,7 @@ |
||
70 | 70 | $this->app->extend($name, function ($instance, $app) use ($class) { |
71 | 71 | return $app->build($class); |
72 | 72 | }); |
73 | - } |
|
74 | - else { |
|
73 | + } else { |
|
75 | 74 | $this->app->singleton($name, function ($app) use ($class) { |
76 | 75 | return $app->build($class); |
77 | 76 | }); |
@@ -63,7 +63,7 @@ discard block |
||
63 | 63 | $app['path.specs'] = $app->basePath().'/resources/specs'; |
64 | 64 | |
65 | 65 | // register spec repository |
66 | - $app->singleton('specs', function ($app) { |
|
66 | + $app->singleton('specs', function($app) { |
|
67 | 67 | $loader = new Repository\FileLoader($app['files'], $app['path.specs']); |
68 | 68 | |
69 | 69 | return new Repository\NamespacedRepository($loader); |
@@ -74,13 +74,13 @@ discard block |
||
74 | 74 | $app->alias('addon', AddonEnvironment::class); |
75 | 75 | |
76 | 76 | // register addon generator |
77 | - $app->singleton('addon.generator', function ($app) { |
|
77 | + $app->singleton('addon.generator', function($app) { |
|
78 | 78 | return new AddonGenerator(); |
79 | 79 | }); |
80 | 80 | $app->alias('addon.generator', AddonGenerator::class); |
81 | 81 | |
82 | 82 | // register database migrator |
83 | - $app->singleton('database.migrator', function ($app) { |
|
83 | + $app->singleton('database.migrator', function($app) { |
|
84 | 84 | return new Migrator($app['db']); |
85 | 85 | }); |
86 | 86 | $app->alias('database.migrator', Migrator::class); |
@@ -111,7 +111,7 @@ discard block |
||
111 | 111 | protected function setupPackageCommands(array $commands) |
112 | 112 | { |
113 | 113 | foreach ($commands as $name => $class) { |
114 | - $this->app->singleton($name, function ($app) use ($class) { |
|
114 | + $this->app->singleton($name, function($app) use ($class) { |
|
115 | 115 | return $app->build($class); |
116 | 116 | }); |
117 | 117 | } |
@@ -11,7 +11,7 @@ discard block |
||
11 | 11 | */ |
12 | 12 | public static function comment() |
13 | 13 | { |
14 | - return function ($value) { |
|
14 | + return function($value) { |
|
15 | 15 | $pattern = sprintf('/%s((.|\s)*?)%s/', '{#', '#}'); |
16 | 16 | |
17 | 17 | return preg_replace($pattern, '<?php /*$1*/ ?>', $value); |
@@ -25,7 +25,7 @@ discard block |
||
25 | 25 | */ |
26 | 26 | public static function script() |
27 | 27 | { |
28 | - return function ($value) { |
|
28 | + return function($value) { |
|
29 | 29 | $pattern = sprintf('/%s((.|\s)*?)%s/', '{@', '@}'); |
30 | 30 | |
31 | 31 | return preg_replace($pattern, '<?php $1; ?>', $value); |
@@ -32,8 +32,7 @@ |
||
32 | 32 | { |
33 | 33 | if (is_string($pathOrSpec)) { |
34 | 34 | $spec = new InputSpec(app('specs'), app('translator'), $pathOrSpec); |
35 | - } |
|
36 | - else { |
|
35 | + } else { |
|
37 | 36 | $spec = $pathOrSpec; |
38 | 37 | } |
39 | 38 |
@@ -81,7 +81,7 @@ |
||
81 | 81 | |
82 | 82 | return $generator->file($path)->template($this->getStub(), [ |
83 | 83 | 'namespace' => $namespace, |
84 | - 'root_namespace' => $this->getAppNamespace(), // use App\Jobs\Job |
|
84 | + 'root_namespace' => $this->getAppNamespace(), // use App\Jobs\Job |
|
85 | 85 | 'class' => $class, |
86 | 86 | ]); |
87 | 87 | } |