@@ -188,13 +188,13 @@ discard block |
||
188 | 188 | |
189 | 189 | if (isset($config) AND is_array($config)) { |
190 | 190 | // Set default timezone |
191 | - if (isset($config[ 'datetime' ][ 'timezone' ])) { |
|
192 | - date_default_timezone_set($config[ 'datetime' ][ 'timezone' ]); |
|
191 | + if (isset($config['datetime']['timezone'])) { |
|
192 | + date_default_timezone_set($config['datetime']['timezone']); |
|
193 | 193 | } |
194 | 194 | |
195 | 195 | // Setup Language Ideom and Locale |
196 | - if (isset($config[ 'language' ])) { |
|
197 | - language()->setDefault($config[ 'language' ]); |
|
196 | + if (isset($config['language'])) { |
|
197 | + language()->setDefault($config['language']); |
|
198 | 198 | } |
199 | 199 | |
200 | 200 | config()->merge($config); |
@@ -424,8 +424,8 @@ discard block |
||
424 | 424 | $packageJsonFile = str_replace(['\\', '/'], DIRECTORY_SEPARATOR, $packageJsonFile); |
425 | 425 | $packageJsonFileInfo = pathinfo($packageJsonFile); |
426 | 426 | |
427 | - if ($packageJsonFileInfo[ 'filename' ] === 'widget' or |
|
428 | - $packageJsonFileInfo[ 'filename' ] === 'language' or |
|
427 | + if ($packageJsonFileInfo['filename'] === 'widget' or |
|
428 | + $packageJsonFileInfo['filename'] === 'language' or |
|
429 | 429 | strpos($packageJsonFile, '.svn') !== false // subversion properties file conflict. |
430 | 430 | ) { |
431 | 431 | continue; |
@@ -455,8 +455,8 @@ discard block |
||
455 | 455 | } |
456 | 456 | |
457 | 457 | if (strpos($packageJsonFile, |
458 | - $modularType = ucfirst(plural($packageJsonFileInfo[ 'filename' ])) . DIRECTORY_SEPARATOR) === false) { |
|
459 | - $modularType = ucfirst($packageJsonFileInfo[ 'filename' ]) . DIRECTORY_SEPARATOR; |
|
458 | + $modularType = ucfirst(plural($packageJsonFileInfo['filename'])) . DIRECTORY_SEPARATOR) === false) { |
|
459 | + $modularType = ucfirst($packageJsonFileInfo['filename']) . DIRECTORY_SEPARATOR; |
|
460 | 460 | } |
461 | 461 | |
462 | 462 | $modularType = strtolower(rtrim($modularType, DIRECTORY_SEPARATOR)); |
@@ -471,7 +471,7 @@ discard block |
||
471 | 471 | PATH_PUBLIC, |
472 | 472 | PATH_RESOURCES, |
473 | 473 | PATH_APP, |
474 | - $packageJsonFileInfo[ 'basename' ], |
|
474 | + $packageJsonFileInfo['basename'], |
|
475 | 475 | ucfirst($modularType) . DIRECTORY_SEPARATOR, |
476 | 476 | ucfirst($modularType . 's') . DIRECTORY_SEPARATOR, // manual plural |
477 | 477 | ], |
@@ -482,7 +482,7 @@ discard block |
||
482 | 482 | ) |
483 | 483 | ); |
484 | 484 | |
485 | - $moduleSegments = array_map(function ($string) { |
|
485 | + $moduleSegments = array_map(function($string) { |
|
486 | 486 | return dash(snakecase($string)); |
487 | 487 | }, $moduleSegments); |
488 | 488 | |
@@ -490,14 +490,14 @@ discard block |
||
490 | 490 | str_replace( |
491 | 491 | PATH_ROOT, |
492 | 492 | '', |
493 | - $packageJsonFileInfo[ 'dirname' ] |
|
493 | + $packageJsonFileInfo['dirname'] |
|
494 | 494 | ), |
495 | 495 | false |
496 | 496 | ); |
497 | 497 | |
498 | - if (isset($packageJsonMetadata[ 'namespace' ])) { |
|
499 | - $moduleNamespace = $packageJsonMetadata[ 'namespace' ]; |
|
500 | - unset($packageJsonMetadata[ 'namespace' ]); |
|
498 | + if (isset($packageJsonMetadata['namespace'])) { |
|
499 | + $moduleNamespace = $packageJsonMetadata['namespace']; |
|
500 | + unset($packageJsonMetadata['namespace']); |
|
501 | 501 | } |
502 | 502 | |
503 | 503 | $moduleParentSegments = []; |
@@ -511,16 +511,16 @@ discard block |
||
511 | 511 | $registryKey = implode('/', $moduleSegments); |
512 | 512 | |
513 | 513 | if ($registryKey === '') { |
514 | - if ($packageJsonFileInfo[ 'dirname' ] . DIRECTORY_SEPARATOR !== PATH_APP and $modularType === 'app') { |
|
514 | + if ($packageJsonFileInfo['dirname'] . DIRECTORY_SEPARATOR !== PATH_APP and $modularType === 'app') { |
|
515 | 515 | $registryKey = dash(snakecase( |
516 | - pathinfo($packageJsonFileInfo[ 'dirname' ], PATHINFO_FILENAME))); |
|
516 | + pathinfo($packageJsonFileInfo['dirname'], PATHINFO_FILENAME))); |
|
517 | 517 | } |
518 | 518 | } |
519 | 519 | |
520 | - $registry[ $registryKey ] = (new DataStructures\Module( |
|
521 | - $packageJsonFileInfo[ 'dirname' ] |
|
520 | + $registry[$registryKey] = (new DataStructures\Module( |
|
521 | + $packageJsonFileInfo['dirname'] |
|
522 | 522 | )) |
523 | - ->setType($packageJsonFileInfo[ 'filename' ]) |
|
523 | + ->setType($packageJsonFileInfo['filename']) |
|
524 | 524 | ->setNamespace($moduleNamespace) |
525 | 525 | ->setSegments($moduleSegments) |
526 | 526 | ->setParentSegments($moduleParentSegments) |
@@ -682,8 +682,8 @@ discard block |
||
682 | 682 | $segment = dash($segment); |
683 | 683 | |
684 | 684 | if ($this->exists($segment)) { |
685 | - if ($this->registry[ $segment ] instanceof DataStructures\Module) { |
|
686 | - return $this->registry[ $segment ]; |
|
685 | + if ($this->registry[$segment] instanceof DataStructures\Module) { |
|
686 | + return $this->registry[$segment]; |
|
687 | 687 | } |
688 | 688 | } |
689 | 689 | |
@@ -719,8 +719,8 @@ discard block |
||
719 | 719 | */ |
720 | 720 | public function first() |
721 | 721 | { |
722 | - if (isset($this->registry[ '' ])) { |
|
723 | - return $this->registry[ '' ]; |
|
722 | + if (isset($this->registry[''])) { |
|
723 | + return $this->registry['']; |
|
724 | 724 | } elseif (reset($this->registry)->type === 'APP') { |
725 | 725 | return reset($this->registry); |
726 | 726 | } |
@@ -742,7 +742,7 @@ discard block |
||
742 | 742 | $segments = (is_array($segments) ? implode('/', array_map('dash', $segments)) : $segments); |
743 | 743 | |
744 | 744 | if ($this->exists($segments)) { |
745 | - return $this->registry[ $segments ]; |
|
745 | + return $this->registry[$segments]; |
|
746 | 746 | } |
747 | 747 | |
748 | 748 | return false; |
@@ -763,7 +763,7 @@ discard block |
||
763 | 763 | |
764 | 764 | foreach ($this as $key => $module) { |
765 | 765 | if ($module instanceof DataStructures\Module) { |
766 | - $namespaces[ $key ] = new SplNamespaceInfo($module->getNamespace(), $module->getRealPath()); |
|
766 | + $namespaces[$key] = new SplNamespaceInfo($module->getNamespace(), $module->getRealPath()); |
|
767 | 767 | } |
768 | 768 | } |
769 | 769 |
@@ -156,8 +156,8 @@ |
||
156 | 156 | */ |
157 | 157 | public function reload() |
158 | 158 | { |
159 | - if(count($this->loaded)) { |
|
160 | - foreach($this->loaded as $filename) { |
|
159 | + if (count($this->loaded)) { |
|
160 | + foreach ($this->loaded as $filename) { |
|
161 | 161 | $this->loadFile($filename); |
162 | 162 | } |
163 | 163 | } |
@@ -105,12 +105,12 @@ discard block |
||
105 | 105 | } |
106 | 106 | |
107 | 107 | // autoload presenter assets |
108 | - if (isset($config[ 'assets' ])) { |
|
109 | - $this->assets->autoload($config[ 'assets' ]); |
|
108 | + if (isset($config['assets'])) { |
|
109 | + $this->assets->autoload($config['assets']); |
|
110 | 110 | } |
111 | 111 | |
112 | 112 | // autoload presenter theme |
113 | - if(isset($config['theme'])) { |
|
113 | + if (isset($config['theme'])) { |
|
114 | 114 | $this->setTheme($config['theme']); |
115 | 115 | } |
116 | 116 | |
@@ -128,19 +128,19 @@ discard block |
||
128 | 128 | */ |
129 | 129 | public function setTheme($theme) |
130 | 130 | { |
131 | - if($this->theme instanceof Theme) { |
|
131 | + if ($this->theme instanceof Theme) { |
|
132 | 132 | $this->assets->removeFilePath($this->theme->getRealPath()); |
133 | 133 | } |
134 | 134 | |
135 | 135 | if (is_bool($theme)) { |
136 | 136 | $this->theme = false; |
137 | - } elseif(($moduleTheme = modules()->top()->getTheme($theme, true)) instanceof Theme) { |
|
137 | + } elseif (($moduleTheme = modules()->top()->getTheme($theme, true)) instanceof Theme) { |
|
138 | 138 | $this->theme = $moduleTheme; |
139 | - } elseif(($appTheme = modules()->first()->getTheme($theme, true)) instanceof Theme) { |
|
139 | + } elseif (($appTheme = modules()->first()->getTheme($theme, true)) instanceof Theme) { |
|
140 | 140 | $this->theme = $appTheme; |
141 | 141 | } |
142 | 142 | |
143 | - if($this->theme) { |
|
143 | + if ($this->theme) { |
|
144 | 144 | if ( ! defined('PATH_THEME')) { |
145 | 145 | define('PATH_THEME', $this->theme->getRealPath()); |
146 | 146 | } |
@@ -148,7 +148,7 @@ discard block |
||
148 | 148 | // add theme assets directory |
149 | 149 | $this->assets->pushFilePath($this->theme->getRealPath()); |
150 | 150 | |
151 | - if(is_dir($themeViewPath = $this->theme->getRealPath() . 'views' . DIRECTORY_SEPARATOR)) { |
|
151 | + if (is_dir($themeViewPath = $this->theme->getRealPath() . 'views' . DIRECTORY_SEPARATOR)) { |
|
152 | 152 | |
153 | 153 | // add theme view directory |
154 | 154 | view()->addFilePath($this->theme->getRealPath()); |
@@ -158,11 +158,11 @@ discard block |
||
158 | 158 | |
159 | 159 | $modules = modules()->getArrayCopy(); |
160 | 160 | |
161 | - foreach($modules as $module) { |
|
161 | + foreach ($modules as $module) { |
|
162 | 162 | if ( ! in_array($module->getType(), ['KERNEL', 'FRAMEWORK', 'APP'])) { |
163 | 163 | $moduleResourcesPath = str_replace(PATH_RESOURCES, '', $module->getResourcesDir()); |
164 | 164 | |
165 | - if(is_dir($themeViewPath . $moduleResourcesPath)) { |
|
165 | + if (is_dir($themeViewPath . $moduleResourcesPath)) { |
|
166 | 166 | view()->pushFilePath($themeViewPath . $moduleResourcesPath); |
167 | 167 | } |
168 | 168 | } |
@@ -203,25 +203,25 @@ discard block |
||
203 | 203 | $storage = $this->storage; |
204 | 204 | |
205 | 205 | // Add Properties |
206 | - $storage[ 'meta' ] = $this->meta; |
|
207 | - $storage[ 'page' ] = $this->page; |
|
208 | - $storage[ 'assets' ] = new SplArrayObject([ |
|
206 | + $storage['meta'] = $this->meta; |
|
207 | + $storage['page'] = $this->page; |
|
208 | + $storage['assets'] = new SplArrayObject([ |
|
209 | 209 | 'head' => $this->assets->getHead(), |
210 | 210 | 'body' => $this->assets->getBody(), |
211 | 211 | ]); |
212 | - $storage[ 'partials' ] = $this->partials; |
|
213 | - $storage[ 'widgets' ] = $this->widgets; |
|
214 | - $storage[ 'theme' ] = $this->theme; |
|
212 | + $storage['partials'] = $this->partials; |
|
213 | + $storage['widgets'] = $this->widgets; |
|
214 | + $storage['theme'] = $this->theme; |
|
215 | 215 | |
216 | 216 | // Add Services |
217 | - $storage[ 'config' ] = config(); |
|
218 | - $storage[ 'language' ] = language(); |
|
219 | - $storage[ 'session' ] = session(); |
|
220 | - $storage[ 'presenter' ] = presenter(); |
|
221 | - $storage[ 'input' ] = input(); |
|
217 | + $storage['config'] = config(); |
|
218 | + $storage['language'] = language(); |
|
219 | + $storage['session'] = session(); |
|
220 | + $storage['presenter'] = presenter(); |
|
221 | + $storage['input'] = input(); |
|
222 | 222 | |
223 | 223 | if (services()->has('csrfProtection')) { |
224 | - $storage[ 'csrfToken' ] = services()->get('csrfProtection')->getToken(); |
|
224 | + $storage['csrfToken'] = services()->get('csrfProtection')->getToken(); |
|
225 | 225 | } |
226 | 226 | |
227 | 227 | return $storage; |
@@ -77,7 +77,7 @@ discard block |
||
77 | 77 | } |
78 | 78 | } else { |
79 | 79 | $uriPath = urldecode( |
80 | - parse_url($_SERVER[ 'REQUEST_URI' ], PHP_URL_PATH) |
|
80 | + parse_url($_SERVER['REQUEST_URI'], PHP_URL_PATH) |
|
81 | 81 | ); |
82 | 82 | |
83 | 83 | $uriPathParts = explode('public/', $uriPath); |
@@ -120,7 +120,7 @@ discard block |
||
120 | 120 | // Module routing |
121 | 121 | if ($numOfUriSegments = count($uriSegments)) { |
122 | 122 | if (empty($app)) { |
123 | - if (false !== ($module = modules()->getModule( reset($uriSegments) ))) { |
|
123 | + if (false !== ($module = modules()->getModule(reset($uriSegments)))) { |
|
124 | 124 | //array_shift($uriSegments); |
125 | 125 | $this->uri = $this->uri->withSegments(new KernelMessageUriSegments($uriSegments)); |
126 | 126 | $uriString = $this->uri->getSegments()->getString(); |
@@ -128,7 +128,7 @@ discard block |
||
128 | 128 | $this->registerModule($module); |
129 | 129 | } |
130 | 130 | } else { |
131 | - if (false !== ($module = modules()->getModule( [$app->getParameter(), reset($uriSegments) ] ))) { |
|
131 | + if (false !== ($module = modules()->getModule([$app->getParameter(), reset($uriSegments)]))) { |
|
132 | 132 | array_shift($uriSegments); |
133 | 133 | $this->uri = $this->uri->withSegments(new KernelMessageUriSegments($uriSegments)); |
134 | 134 | $uriString = $this->uri->getSegments()->getString(); |
@@ -137,7 +137,7 @@ discard block |
||
137 | 137 | } |
138 | 138 | } |
139 | 139 | |
140 | - if($numOfUriSegments = count($uriSegments)) { |
|
140 | + if ($numOfUriSegments = count($uriSegments)) { |
|
141 | 141 | for ($i = 0; $i <= $numOfUriSegments; $i++) { |
142 | 142 | $uriRoutedSegments = array_diff($uriSegments, |
143 | 143 | array_slice($uriSegments, ($numOfUriSegments - $i))); |
@@ -228,7 +228,7 @@ discard block |
||
228 | 228 | if (class_exists($controllerClassName = $controllerNamespace . implode('\\', |
229 | 229 | array_map('studlycase', $uriRoutedSegments)))) { |
230 | 230 | |
231 | - if($controllerClassName::$inherited) { |
|
231 | + if ($controllerClassName::$inherited) { |
|
232 | 232 | $uriSegments = array_diff($uriSegments, $uriRoutedSegments); |
233 | 233 | $this->setController(new KernelControllerDataStructure($controllerClassName), |
234 | 234 | $uriSegments); |
@@ -245,7 +245,7 @@ discard block |
||
245 | 245 | * Try to find requested page |
246 | 246 | */ |
247 | 247 | if (false !== ($pagesDir = $module->getResourcesDir('pages', true))) { |
248 | - if($controllerClassName = $this->getPagesControllerClassName()) { |
|
248 | + if ($controllerClassName = $this->getPagesControllerClassName()) { |
|
249 | 249 | |
250 | 250 | /** |
251 | 251 | * Try to find from database |
@@ -280,12 +280,12 @@ discard block |
||
280 | 280 | presenter()->page->setFile($pageFilePath); |
281 | 281 | } else { |
282 | 282 | $pageFilePath = str_replace('.phtml', DIRECTORY_SEPARATOR . 'index.phtml', $pageFilePath); |
283 | - if(is_file($pageFilePath)) { |
|
283 | + if (is_file($pageFilePath)) { |
|
284 | 284 | presenter()->page->setFile($pageFilePath); |
285 | 285 | } |
286 | 286 | } |
287 | 287 | |
288 | - if(presenter()->page->file instanceof SplFileInfo) { |
|
288 | + if (presenter()->page->file instanceof SplFileInfo) { |
|
289 | 289 | $this->setController( |
290 | 290 | (new KernelControllerDataStructure($controllerClassName)) |
291 | 291 | ->setRequestMethod('index') |
@@ -328,19 +328,19 @@ discard block |
||
328 | 328 | { |
329 | 329 | $modules = modules()->getArrayCopy(); |
330 | 330 | |
331 | - foreach($modules as $module) { |
|
331 | + foreach ($modules as $module) { |
|
332 | 332 | $controllerClassName = $module->getNamespace() . 'Controllers\Pages'; |
333 | 333 | if ($module->getNamespace() === 'O2System\Framework\\') { |
334 | 334 | $controllerClassName = 'O2System\Framework\Http\Controllers\Pages'; |
335 | 335 | } |
336 | 336 | |
337 | - if(class_exists($controllerClassName)) { |
|
337 | + if (class_exists($controllerClassName)) { |
|
338 | 338 | return $controllerClassName; |
339 | 339 | break; |
340 | 340 | } |
341 | 341 | } |
342 | 342 | |
343 | - if(class_exists('O2System\Framework\Http\Controllers\Pages')) { |
|
343 | + if (class_exists('O2System\Framework\Http\Controllers\Pages')) { |
|
344 | 344 | return 'O2System\Framework\Http\Controllers\Pages'; |
345 | 345 | } |
346 | 346 | |
@@ -391,7 +391,7 @@ discard block |
||
391 | 391 | if (class_exists($controllerClassName)) { |
392 | 392 | $this->addresses->any( |
393 | 393 | '/', |
394 | - function () use ($controllerClassName) { |
|
394 | + function() use ($controllerClassName) { |
|
395 | 395 | return new $controllerClassName(); |
396 | 396 | } |
397 | 397 | ); |
@@ -406,7 +406,7 @@ discard block |
||
406 | 406 | if (class_exists($controllerClassName)) { |
407 | 407 | $this->addresses->any( |
408 | 408 | '/', |
409 | - function () use ($controllerClassName) { |
|
409 | + function() use ($controllerClassName) { |
|
410 | 410 | return new $controllerClassName(); |
411 | 411 | } |
412 | 412 | ); |
@@ -458,8 +458,8 @@ discard block |
||
458 | 458 | ); |
459 | 459 | } elseif (preg_match("/([a-zA-Z0-9\\\]+)(@)([a-zA-Z0-9\\\]+)/", $closure, $matches)) { |
460 | 460 | $this->setController( |
461 | - (new KernelControllerDataStructure($matches[ 1 ])) |
|
462 | - ->setRequestMethod($matches[ 3 ]), |
|
461 | + (new KernelControllerDataStructure($matches[1])) |
|
462 | + ->setRequestMethod($matches[3]), |
|
463 | 463 | $uriSegments |
464 | 464 | ); |
465 | 465 | } elseif (presenter()->theme->use === true) { |
@@ -118,7 +118,7 @@ discard block |
||
118 | 118 | self::POST_CONTROLLER, |
119 | 119 | self::POST_COMMANDER, |
120 | 120 | ])) { |
121 | - $this->closures[ $offset ][ spl_object_hash($closure) ] = $closure; |
|
121 | + $this->closures[$offset][spl_object_hash($closure)] = $closure; |
|
122 | 122 | } |
123 | 123 | } |
124 | 124 | |
@@ -132,7 +132,7 @@ discard block |
||
132 | 132 | public function callEvent($event) |
133 | 133 | { |
134 | 134 | if (array_key_exists($event, $this->closures)) { |
135 | - foreach ($this->closures[ $event ] as $closure) { |
|
135 | + foreach ($this->closures[$event] as $closure) { |
|
136 | 136 | call_user_func($closure); |
137 | 137 | } |
138 | 138 | } |
@@ -173,7 +173,7 @@ |
||
173 | 173 | $phar->buildFromIterator(new \RecursiveIteratorIterator(new \RecursiveCallbackFilterIterator( |
174 | 174 | new \RecursiveDirectoryIterator(PATH_ROOT, |
175 | 175 | \FilesystemIterator::SKIP_DOTS | \FilesystemIterator::FOLLOW_SYMLINKS), |
176 | - function ($current, $key, $iterator) { |
|
176 | + function($current, $key, $iterator) { |
|
177 | 177 | if ($current->isDir()) { |
178 | 178 | // exclude build directory |
179 | 179 | if ($current->getFilename() === 'build') { |
@@ -191,16 +191,16 @@ discard block |
||
191 | 191 | $options = input()->get(); |
192 | 192 | |
193 | 193 | if (empty($options)) { |
194 | - $_GET[ 'switch' ] = 'ON'; |
|
195 | - $_GET[ 'mode' ] = 'default'; |
|
196 | - $_GET[ 'lifetime' ] = 300; |
|
197 | - $_GET[ 'title' ] = language()->getLine(strtoupper('CLI_MAINTENANCE_TITLE')); |
|
198 | - $_GET[ 'message' ] = language()->getLine(strtoupper('CLI_MAINTENANCE_MESSAGE')); |
|
194 | + $_GET['switch'] = 'ON'; |
|
195 | + $_GET['mode'] = 'default'; |
|
196 | + $_GET['lifetime'] = 300; |
|
197 | + $_GET['title'] = language()->getLine(strtoupper('CLI_MAINTENANCE_TITLE')); |
|
198 | + $_GET['message'] = language()->getLine(strtoupper('CLI_MAINTENANCE_MESSAGE')); |
|
199 | 199 | } else { |
200 | - $_GET[ 'mode' ] = 'default'; |
|
201 | - $_GET[ 'lifetime' ] = 300; |
|
202 | - $_GET[ 'title' ] = language()->getLine(strtoupper('CLI_MAINTENANCE_TITLE')); |
|
203 | - $_GET[ 'message' ] = language()->getLine(strtoupper('CLI_MAINTENANCE_MESSAGE')); |
|
200 | + $_GET['mode'] = 'default'; |
|
201 | + $_GET['lifetime'] = 300; |
|
202 | + $_GET['title'] = language()->getLine(strtoupper('CLI_MAINTENANCE_TITLE')); |
|
203 | + $_GET['message'] = language()->getLine(strtoupper('CLI_MAINTENANCE_MESSAGE')); |
|
204 | 204 | } |
205 | 205 | |
206 | 206 | $this->__callOptions(); |
@@ -213,11 +213,11 @@ discard block |
||
213 | 213 | (new Format()) |
214 | 214 | ->setContextualClass(Format::DANGER) |
215 | 215 | ->setString(language()->getLine('CLI_MAINTENANCE_ALREADY_STARTED', [ |
216 | - $maintenanceInfo[ 'mode' ], |
|
217 | - $maintenanceInfo[ 'datetime' ], |
|
218 | - date('r', strtotime($maintenanceInfo[ 'datetime' ]) + $maintenanceInfo[ 'lifetime' ]), |
|
219 | - $maintenanceInfo[ 'title' ], |
|
220 | - $maintenanceInfo[ 'message' ], |
|
216 | + $maintenanceInfo['mode'], |
|
217 | + $maintenanceInfo['datetime'], |
|
218 | + date('r', strtotime($maintenanceInfo['datetime']) + $maintenanceInfo['lifetime']), |
|
219 | + $maintenanceInfo['title'], |
|
220 | + $maintenanceInfo['message'], |
|
221 | 221 | ])) |
222 | 222 | ->setNewLinesAfter(1) |
223 | 223 | ); |
@@ -113,8 +113,8 @@ discard block |
||
113 | 113 | $options = input()->get(); |
114 | 114 | |
115 | 115 | if (empty($options)) { |
116 | - $_GET[ 'host' ] = 'localhost'; |
|
117 | - $_GET[ 'port' ] = 8000; |
|
116 | + $_GET['host'] = 'localhost'; |
|
117 | + $_GET['port'] = 8000; |
|
118 | 118 | } |
119 | 119 | |
120 | 120 | $this->__callOptions(); |
@@ -126,12 +126,12 @@ discard block |
||
126 | 126 | ->setNewLinesAfter(1) |
127 | 127 | ); |
128 | 128 | |
129 | - $_SERVER[ 'DOCUMENT_ROOT' ] = PATH_PUBLIC; |
|
129 | + $_SERVER['DOCUMENT_ROOT'] = PATH_PUBLIC; |
|
130 | 130 | |
131 | 131 | output()->write( |
132 | 132 | (new Format()) |
133 | 133 | ->setContextualClass(Format::INFO) |
134 | - ->setString(language()->getLine('CLI_SERVE_DOC_ROOT', [$_SERVER[ 'DOCUMENT_ROOT' ]])) |
|
134 | + ->setString(language()->getLine('CLI_SERVE_DOC_ROOT', [$_SERVER['DOCUMENT_ROOT']])) |
|
135 | 135 | ->setNewLinesAfter(1) |
136 | 136 | ); |
137 | 137 |