@@ -31,10 +31,10 @@ discard block |
||
31 | 31 | */ |
32 | 32 | public function register() |
33 | 33 | { |
34 | - $this->mergeConfigFrom(__DIR__.'/../config/artomator.php', 'artomator'); |
|
34 | + $this->mergeConfigFrom(__DIR__ . '/../config/artomator.php', 'artomator'); |
|
35 | 35 | |
36 | 36 | // Register the service the package provides. |
37 | - $this->app->singleton('artomator', function ($app) { |
|
37 | + $this->app->singleton('artomator', function($app) { |
|
38 | 38 | return new Artomator; |
39 | 39 | }); |
40 | 40 | } |
@@ -58,7 +58,7 @@ discard block |
||
58 | 58 | { |
59 | 59 | // Publishing the configuration file. |
60 | 60 | $this->publishes([ |
61 | - __DIR__.'/../config/artomator.php' => config_path('artomator.php'), |
|
61 | + __DIR__ . '/../config/artomator.php' => config_path('artomator.php'), |
|
62 | 62 | ], 'artomator.config'); |
63 | 63 | |
64 | 64 | // Publishing the views. |
@@ -68,7 +68,7 @@ discard block |
||
68 | 68 | |
69 | 69 | // Publishing stubs. |
70 | 70 | $this->publishes([ |
71 | - __DIR__.'/Commands/stubs' => public_path('vendor/pwweb'), |
|
71 | + __DIR__ . '/Commands/stubs' => public_path('vendor/pwweb'), |
|
72 | 72 | ], 'artomator.stubs'); |
73 | 73 | |
74 | 74 | // Publishing assets. |
@@ -65,7 +65,7 @@ discard block |
||
65 | 65 | */ |
66 | 66 | protected function getDefaultNamespace($rootNamespace) |
67 | 67 | { |
68 | - return $rootNamespace.'\GraphQL\Type'; |
|
68 | + return $rootNamespace . '\GraphQL\Type'; |
|
69 | 69 | } |
70 | 70 | |
71 | 71 | /** |
@@ -185,8 +185,8 @@ discard block |
||
185 | 185 | |
186 | 186 | $model = trim(str_replace('/', '\\', $model), '\\'); |
187 | 187 | |
188 | - if (! Str::startsWith($model, $rootNamespace = $this->laravel->getNamespace())) { |
|
189 | - $model = $rootNamespace.'Models\\'.$model; |
|
188 | + if (!Str::startsWith($model, $rootNamespace = $this->laravel->getNamespace())) { |
|
189 | + $model = $rootNamespace . 'Models\\' . $model; |
|
190 | 190 | } |
191 | 191 | |
192 | 192 | return $model; |
@@ -65,7 +65,7 @@ discard block |
||
65 | 65 | */ |
66 | 66 | protected function getDefaultNamespace($rootNamespace) |
67 | 67 | { |
68 | - return $rootNamespace.'\Http\Controllers'; |
|
68 | + return $rootNamespace . '\Http\Controllers'; |
|
69 | 69 | } |
70 | 70 | |
71 | 71 | /** |
@@ -149,7 +149,7 @@ discard block |
||
149 | 149 | { |
150 | 150 | $modelClass = $this->parseModel($this->option('model')); |
151 | 151 | |
152 | - if (! class_exists($modelClass)) { |
|
152 | + if (!class_exists($modelClass)) { |
|
153 | 153 | if ($this->confirm("A {$modelClass} model does not exist. Do you want to generate it?", true)) { |
154 | 154 | $this->call('make:model', ['name' => $modelClass]); |
155 | 155 | } |
@@ -219,8 +219,8 @@ discard block |
||
219 | 219 | |
220 | 220 | $model = trim(str_replace('/', '\\', $model), '\\'); |
221 | 221 | |
222 | - if (! Str::startsWith($model, $rootNamespace = $this->laravel->getNamespace())) { |
|
223 | - $model = $rootNamespace.'Models\\'.$model; |
|
222 | + if (!Str::startsWith($model, $rootNamespace = $this->laravel->getNamespace())) { |
|
223 | + $model = $rootNamespace . 'Models\\' . $model; |
|
224 | 224 | } |
225 | 225 | |
226 | 226 | return $model; |
@@ -66,7 +66,7 @@ discard block |
||
66 | 66 | */ |
67 | 67 | protected function getDefaultNamespace($rootNamespace) |
68 | 68 | { |
69 | - return $rootNamespace.'\Models'; |
|
69 | + return $rootNamespace . '\Models'; |
|
70 | 70 | } |
71 | 71 | |
72 | 72 | /** |
@@ -78,7 +78,7 @@ discard block |
||
78 | 78 | { |
79 | 79 | $this->parseIncludes(); |
80 | 80 | |
81 | - if (in_array('model', $this->includes) === true && parent::handle() === false && ! $this->option('force')) { |
|
81 | + if (in_array('model', $this->includes) === true && parent::handle() === false && !$this->option('force')) { |
|
82 | 82 | return false; |
83 | 83 | } |
84 | 84 |
@@ -128,8 +128,8 @@ discard block |
||
128 | 128 | |
129 | 129 | $model = trim(str_replace('/', '\\', $model), '\\'); |
130 | 130 | |
131 | - if (! Str::startsWith($model, $rootNamespace = $this->laravel->getNamespace())) { |
|
132 | - $model = $rootNamespace.'Models\\'.$model; |
|
131 | + if (!Str::startsWith($model, $rootNamespace = $this->laravel->getNamespace())) { |
|
132 | + $model = $rootNamespace . 'Models\\' . $model; |
|
133 | 133 | } |
134 | 134 | |
135 | 135 | return $model; |
@@ -143,7 +143,7 @@ discard block |
||
143 | 143 | */ |
144 | 144 | protected function getDefaultNamespace($rootNamespace) |
145 | 145 | { |
146 | - return $rootNamespace.'\Http\Requests'; |
|
146 | + return $rootNamespace . '\Http\Requests'; |
|
147 | 147 | } |
148 | 148 | |
149 | 149 | /** |
@@ -65,7 +65,7 @@ discard block |
||
65 | 65 | */ |
66 | 66 | protected function getDefaultNamespace($rootNamespace) |
67 | 67 | { |
68 | - return $rootNamespace.'\GraphQL\Query'; |
|
68 | + return $rootNamespace . '\GraphQL\Query'; |
|
69 | 69 | } |
70 | 70 | |
71 | 71 | /** |
@@ -187,8 +187,8 @@ discard block |
||
187 | 187 | |
188 | 188 | $model = trim(str_replace('/', '\\', $model), '\\'); |
189 | 189 | |
190 | - if (! Str::startsWith($model, $rootNamespace = $this->laravel->getNamespace())) { |
|
191 | - $model = $rootNamespace.'Models\\'.$model; |
|
190 | + if (!Str::startsWith($model, $rootNamespace = $this->laravel->getNamespace())) { |
|
191 | + $model = $rootNamespace . 'Models\\' . $model; |
|
192 | 192 | } |
193 | 193 | |
194 | 194 | return $model; |
@@ -82,7 +82,7 @@ discard block |
||
82 | 82 | return ''; |
83 | 83 | } |
84 | 84 | |
85 | - $fields = array_map(function ($field) { |
|
85 | + $fields = array_map(function($field) { |
|
86 | 86 | return $this->addArg($field); |
87 | 87 | }, $schema); |
88 | 88 | |
@@ -115,7 +115,7 @@ discard block |
||
115 | 115 | return ''; |
116 | 116 | } |
117 | 117 | |
118 | - $fields = array_map(function ($field) { |
|
118 | + $fields = array_map(function($field) { |
|
119 | 119 | return $this->addResolve($field); |
120 | 120 | }, $schema); |
121 | 121 | |
@@ -148,7 +148,7 @@ discard block |
||
148 | 148 | return ''; |
149 | 149 | } |
150 | 150 | |
151 | - $fields = array_map(function ($field) { |
|
151 | + $fields = array_map(function($field) { |
|
152 | 152 | return $this->addField($field); |
153 | 153 | }, $schema); |
154 | 154 | |
@@ -188,7 +188,7 @@ discard block |
||
188 | 188 | return ''; |
189 | 189 | } |
190 | 190 | |
191 | - $fields = array_map(function ($field) { |
|
191 | + $fields = array_map(function($field) { |
|
192 | 192 | return $this->addData($field); |
193 | 193 | }, $schema); |
194 | 194 |