改名
This commit is contained in:
+541
-542
File diff suppressed because it is too large
Load Diff
@@ -97,9 +97,8 @@ class HTTPServerListener extends Abstracts\Server
|
|||||||
[$request, $response] = [HRequest::create($request), HResponse::create($response)];
|
[$request, $response] = [HRequest::create($request), HResponse::create($response)];
|
||||||
if ($request->is('favicon.ico')) {
|
if ($request->is('favicon.ico')) {
|
||||||
throw new Exception('Not found.', 404);
|
throw new Exception('Not found.', 404);
|
||||||
} else {
|
|
||||||
$this->router->dispatch();
|
|
||||||
}
|
}
|
||||||
|
$this->router->dispatch();
|
||||||
} catch (ExitException | Error | Throwable $exception) {
|
} catch (ExitException | Error | Throwable $exception) {
|
||||||
$response->status($exception->getCode() == 0 ? 500 : $exception->getCode());
|
$response->status($exception->getCode() == 0 ? 500 : $exception->getCode());
|
||||||
$response->end($exception->getMessage());
|
$response->end($exception->getMessage());
|
||||||
|
|||||||
Reference in New Issue
Block a user