From ca50c16f887bc4249a64c22871c7a6582789bf4e Mon Sep 17 00:00:00 2001 From: "as2252258@163.com" Date: Sun, 11 Jul 2021 04:05:15 +0800 Subject: [PATCH] modify --- HttpServer/Route/Node.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/HttpServer/Route/Node.php b/HttpServer/Route/Node.php index b611ddc1..c2f79af6 100644 --- a/HttpServer/Route/Node.php +++ b/HttpServer/Route/Node.php @@ -92,7 +92,7 @@ class Node extends HttpService { if (is_string($handler) && str_contains($handler, '@')) { list($controller, $action) = explode('@', $handler); - if (!empty($this->namespace)) { + if (!class_exists($controller) || !empty($this->namespace)) { $controller = implode('\\', $this->namespace) . '\\' . $controller; } $this->handler = $this->getReflect($controller, $action);