| @@ 144-151 (lines=8) @@ | ||
| 141 | * Finish it |
|
| 142 | * @return void |
|
| 143 | */ |
|
| 144 | public function end() |
|
| 145 | { |
|
| 146 | if ($messages = Logger::get('error')) { |
|
| 147 | foreach ($messages as $message) { |
|
| 148 | errorLog(new \ErrorException($message, 0, E_USER_ERROR)); |
|
| 149 | } |
|
| 150 | } |
|
| 151 | } |
|
| 152 | } |
|
| 153 | ||
| @@ 186-200 (lines=15) @@ | ||
| 183 | /** |
|
| 184 | * @return void |
|
| 185 | */ |
|
| 186 | public function end() |
|
| 187 | { |
|
| 188 | if ($messages = Logger::get('error')) { |
|
| 189 | foreach ($messages as $message) { |
|
| 190 | errorLog(new \ErrorException($message, 0, E_USER_ERROR)); |
|
| 191 | } |
|
| 192 | } |
|
| 193 | ||
| 194 | // return code 1 for invalid behaviour of application |
|
| 195 | // if ($exception = $this->getException()) { |
|
| 196 | // echo $exception->getMessage(); |
|
| 197 | // exit(1); |
|
| 198 | // } |
|
| 199 | exit; |
|
| 200 | } |
|
| 201 | } |
|
| 202 | ||