改名
This commit is contained in:
@@ -39,9 +39,9 @@ class TestRequest
|
|||||||
/** @var Handler $handler */
|
/** @var Handler $handler */
|
||||||
$handler = HandlerManager::get($request->server['request_uri'], $request->getMethod());
|
$handler = HandlerManager::get($request->server['request_uri'], $request->getMethod());
|
||||||
if (is_integer($handler)) {
|
if (is_integer($handler)) {
|
||||||
$PsrResponse->withStatus($handler)->withBody(null);
|
$PsrResponse->withStatus($handler)->withBody(new Stream('Allow Method[' . $request->getMethod() . '].'));
|
||||||
} else if (is_null($handler)) {
|
} else if (is_null($handler)) {
|
||||||
$PsrResponse->withStatus(404)->withBody(null);
|
$PsrResponse->withStatus(404)->withBody(new Stream('Page not found.'));
|
||||||
} else {
|
} else {
|
||||||
$PsrResponse = $this->handler($handler, $PsrRequest);
|
$PsrResponse = $this->handler($handler, $PsrRequest);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user