This commit is contained in:
2020-08-31 12:49:37 +08:00
parent 849e261943
commit 2e04459060
+3
View File
@@ -435,6 +435,9 @@ class Router extends Application implements RouterInterface
return JSON::to(404, 'Page not found.');
}
if (empty($node->callback)) {
if (!empty($node->getError())) {
return JSON::to(500, $node->getError());
}
return JSON::to(404, 'Page not found.');
}
return call_user_func($node->callback, $request);