This commit is contained in:
2021-04-27 17:16:07 +08:00
parent aa9b34ec11
commit c9239177db
+6 -6
View File
@@ -482,14 +482,14 @@ class Router extends HttpService implements RouterInterface
*/
public function dispatch(): mixed
{
if (!($node = $this->find_path(\request()))) {
if (!($node = $this->Branch_search(\request()))) {
return send(self::NOT_FOUND);
}
return send(($response = $node->dispatch()), 200);
// if (!$node->hasAfter()) {
// return null;
// }
// return $node->afterDispatch($response);
send(($response = $node->dispatch()), 200);
if (!$node->hasAfter()) {
return null;
}
return $node->afterDispatch($response);
}