@@ -43,17 +43,17 @@ discard block |
||
| 43 | 43 | $this->debug->info('==============================='); |
| 44 | 44 | $this->debug->time('loading application'); |
| 45 | 45 | $appLoader->load(); |
| 46 | - $this->event->exec('application:load-config', [ $this->config ,$this]); |
|
| 46 | + $this->event->exec('application:load-config', [$this->config, $this]); |
|
| 47 | 47 | $this->debug->timeEnd('loading application'); |
| 48 | 48 | $this->debug->time('loading data-source'); |
| 49 | 49 | $appLoader->loadDataSource(); |
| 50 | 50 | $this->debug->timeEnd('loading data-source'); |
| 51 | 51 | Table::load($this); |
| 52 | 52 | DataAccess::loadApplication($this); |
| 53 | - $this->event->exec('application:load-environment', [ $this->config ,$this]); |
|
| 53 | + $this->event->exec('application:load-environment', [$this->config, $this]); |
|
| 54 | 54 | $this->debug->time('loading route'); |
| 55 | 55 | $appLoader->loadRoute(); |
| 56 | - $this->event->exec('application:load-route', [$this->route , $this]); |
|
| 56 | + $this->event->exec('application:load-route', [$this->route, $this]); |
|
| 57 | 57 | $this->debug->timeEnd('loading route'); |
| 58 | 58 | $this->debug->info('-------------------------------'); |
| 59 | 59 | } |
@@ -109,7 +109,7 @@ discard block |
||
| 109 | 109 | if (!$response->isSend()) { |
| 110 | 110 | $response->end(); |
| 111 | 111 | } |
| 112 | - $this->debug->info('responded with code '. $response->getStatus()); |
|
| 112 | + $this->debug->info('responded with code '.$response->getStatus()); |
|
| 113 | 113 | $this->debug->timeEnd('sending response'); |
| 114 | 114 | } catch (Throwable $e) { |
| 115 | 115 | $this->debug->uncaughtException($e); |
@@ -176,7 +176,7 @@ discard block |
||
| 176 | 176 | protected function createResponse(?MatchResult $result, Request $request, Response $response) |
| 177 | 177 | { |
| 178 | 178 | if (SUDA_DEBUG) { |
| 179 | - $response->setHeader('x-route', $result === null?'default':$result->getName()); |
|
| 179 | + $response->setHeader('x-route', $result === null ? 'default' : $result->getName()); |
|
| 180 | 180 | } |
| 181 | 181 | if ($result === null) { |
| 182 | 182 | $content = $this->defaultResponse($this, $request, $response); |
@@ -59,7 +59,7 @@ discard block |
||
| 59 | 59 | if (array_key_exists($name, $this->config) === false) { |
| 60 | 60 | throw new ConfigurationException('missing statement @resource:'.$this->name.'#'.$name); |
| 61 | 61 | } |
| 62 | - $config = $this->config[$name]; |
|
| 62 | + $config = $this->config[$name]; |
|
| 63 | 63 | return (new QueryStatementBuilder($this->access, $config))->build(); |
| 64 | 64 | } |
| 65 | 65 | |
@@ -91,7 +91,7 @@ discard block |
||
| 91 | 91 | list($module, $group, $name) = $application->parseRouteName($name); |
| 92 | 92 | } |
| 93 | 93 | if ($module !== null && ($moduleObj = $application->find($module))) { |
| 94 | - $res = $moduleObj->getResource(); |
|
| 94 | + $res = $moduleObj->getResource(); |
|
| 95 | 95 | } else { |
| 96 | 96 | $res = $application->getResource(); |
| 97 | 97 | } |