@@ -135,7 +135,7 @@ |
||
135 | 135 | $process->setTimeout($this->timeout); |
136 | 136 | |
137 | 137 | if ($this->console instanceof Command) { |
138 | - $process->run(function ($type, $line) { |
|
138 | + $process->run(function($type, $line) { |
|
139 | 139 | $this->console->line($line); |
140 | 140 | }); |
141 | 141 | } |
@@ -169,17 +169,17 @@ |
||
169 | 169 | */ |
170 | 170 | public function publish() |
171 | 171 | { |
172 | - if (! $this->console instanceof Command) { |
|
172 | + if (!$this->console instanceof Command) { |
|
173 | 173 | $message = "The 'console' property must instance of \\Illuminate\\Console\\Command."; |
174 | 174 | |
175 | 175 | throw new \RuntimeException($message); |
176 | 176 | } |
177 | 177 | |
178 | - if (! $this->getFilesystem()->isDirectory($sourcePath = $this->getSourcePath())) { |
|
178 | + if (!$this->getFilesystem()->isDirectory($sourcePath = $this->getSourcePath())) { |
|
179 | 179 | return; |
180 | 180 | } |
181 | 181 | |
182 | - if (! $this->getFilesystem()->isDirectory($destinationPath = $this->getDestinationPath())) { |
|
182 | + if (!$this->getFilesystem()->isDirectory($destinationPath = $this->getDestinationPath())) { |
|
183 | 183 | $this->getFilesystem()->makeDirectory($destinationPath, 0775, true); |
184 | 184 | } |
185 | 185 |
@@ -132,7 +132,7 @@ |
||
132 | 132 | public function generate() |
133 | 133 | { |
134 | 134 | $path = $this->getPath(); |
135 | - if (! $this->filesystem->exists($path)) { |
|
135 | + if (!$this->filesystem->exists($path)) { |
|
136 | 136 | return $this->filesystem->put($path, $this->getContents()); |
137 | 137 | } |
138 | 138 | if ($this->overwriteFile === true) { |
@@ -44,7 +44,7 @@ discard block |
||
44 | 44 | $concatenatedPackages .= "\"{$name}:{$version}\" "; |
45 | 45 | } |
46 | 46 | |
47 | - if (! empty($concatenatedPackages)) { |
|
47 | + if (!empty($concatenatedPackages)) { |
|
48 | 48 | $this->run("composer require {$concatenatedPackages}{$this->isComposerSilenced()}"); |
49 | 49 | } |
50 | 50 | } |
@@ -61,7 +61,7 @@ discard block |
||
61 | 61 | $concatenatedPackages .= "\"{$name}:{$version}\" "; |
62 | 62 | } |
63 | 63 | |
64 | - if (! empty($concatenatedPackages)) { |
|
64 | + if (!empty($concatenatedPackages)) { |
|
65 | 65 | $this->run("composer require --dev {$concatenatedPackages}{$this->isComposerSilenced()}"); |
66 | 66 | } |
67 | 67 | } |
@@ -28,7 +28,7 @@ |
||
28 | 28 | public function handle(): int |
29 | 29 | { |
30 | 30 | $this->components->twoColumnDetail('<fg=gray>Status / Name</>', '<fg=gray>Path / priority</>'); |
31 | - collect($this->getRows())->each(function ($row) { |
|
31 | + collect($this->getRows())->each(function($row) { |
|
32 | 32 | |
33 | 33 | $this->components->twoColumnDetail("[{$row[1]}] {$row[0]}", "{$row[3]} [{$row[2]}]"); |
34 | 34 | }); |
@@ -17,7 +17,7 @@ |
||
17 | 17 | { |
18 | 18 | // This checks if we are running on a Laravel Vapor managed instance |
19 | 19 | // and sets the path to a writable one (services path is not on a writable storage in Vapor). |
20 | - if (! is_null(env('VAPOR_MAINTENANCE_MODE', null))) { |
|
20 | + if (!is_null(env('VAPOR_MAINTENANCE_MODE', null))) { |
|
21 | 21 | return Str::replaceLast('config.php', $this->getSnakeName().'_module.php', $this->app->getCachedConfigPath()); |
22 | 22 | } |
23 | 23 |
@@ -109,7 +109,7 @@ discard block |
||
109 | 109 | */ |
110 | 110 | public function hasStatus(Module $module, bool $status): bool |
111 | 111 | { |
112 | - if (! isset($this->modulesStatuses[$module->getName()])) { |
|
112 | + if (!isset($this->modulesStatuses[$module->getName()])) { |
|
113 | 113 | return $status === false; |
114 | 114 | } |
115 | 115 | |
@@ -139,7 +139,7 @@ discard block |
||
139 | 139 | */ |
140 | 140 | public function delete(Module $module): void |
141 | 141 | { |
142 | - if (! isset($this->modulesStatuses[$module->getName()])) { |
|
142 | + if (!isset($this->modulesStatuses[$module->getName()])) { |
|
143 | 143 | return; |
144 | 144 | } |
145 | 145 | unset($this->modulesStatuses[$module->getName()]); |
@@ -162,7 +162,7 @@ discard block |
||
162 | 162 | */ |
163 | 163 | private function readJson(): array |
164 | 164 | { |
165 | - if (! $this->files->exists($this->statusesFile)) { |
|
165 | + if (!$this->files->exists($this->statusesFile)) { |
|
166 | 166 | return []; |
167 | 167 | } |
168 | 168 | |
@@ -177,11 +177,11 @@ discard block |
||
177 | 177 | */ |
178 | 178 | private function getModulesStatuses(): array |
179 | 179 | { |
180 | - if (! $this->config->get('modules.cache.enabled')) { |
|
180 | + if (!$this->config->get('modules.cache.enabled')) { |
|
181 | 181 | return $this->readJson(); |
182 | 182 | } |
183 | 183 | |
184 | - return $this->cache->store($this->config->get('modules.cache.driver'))->remember($this->cacheKey, $this->cacheLifetime, function () { |
|
184 | + return $this->cache->store($this->config->get('modules.cache.driver'))->remember($this->cacheKey, $this->cacheLifetime, function() { |
|
185 | 185 | return $this->readJson(); |
186 | 186 | }); |
187 | 187 | } |
@@ -24,7 +24,7 @@ |
||
24 | 24 | */ |
25 | 25 | public function toArray() |
26 | 26 | { |
27 | - return array_map(function ($value) { |
|
27 | + return array_map(function($value) { |
|
28 | 28 | if ($value instanceof Module) { |
29 | 29 | $attributes = $value->json()->getAttributes(); |
30 | 30 | $attributes['path'] = $value->getPath(); |
@@ -98,7 +98,7 @@ discard block |
||
98 | 98 | */ |
99 | 99 | public function getMigrations($reverse = false) |
100 | 100 | { |
101 | - if (! empty($this->subpath)) { |
|
101 | + if (!empty($this->subpath)) { |
|
102 | 102 | $files = $this->laravel['files']->glob($this->getPath().'/'.$this->subpath); |
103 | 103 | } else { |
104 | 104 | $files = $this->laravel['files']->glob($this->getPath().'/*_*.php'); |
@@ -111,7 +111,7 @@ discard block |
||
111 | 111 | return []; |
112 | 112 | } |
113 | 113 | |
114 | - $files = array_map(function ($file) { |
|
114 | + $files = array_map(function($file) { |
|
115 | 115 | return str_replace('.php', '', basename($file)); |
116 | 116 | }, $files); |
117 | 117 | |
@@ -215,7 +215,7 @@ discard block |
||
215 | 215 | |
216 | 216 | $class = Str::studly($name); |
217 | 217 | |
218 | - if (! class_exists($class) && file_exists($this->getPath().'/'.$file.'.php')) { |
|
218 | + if (!class_exists($class) && file_exists($this->getPath().'/'.$file.'.php')) { |
|
219 | 219 | return include $this->getPath().'/'.$file.'.php'; |
220 | 220 | } |
221 | 221 | |
@@ -309,7 +309,7 @@ discard block |
||
309 | 309 | |
310 | 310 | $result = $query->orderBy('migration', 'desc')->get(); |
311 | 311 | |
312 | - return collect($result)->map(function ($item) { |
|
312 | + return collect($result)->map(function($item) { |
|
313 | 313 | return (array) $item; |
314 | 314 | })->pluck('migration'); |
315 | 315 | } |