From b1081dd079c75112eb9ec54102a2a4f0c82d2738 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mr=C2=B7x?= Date: Mon, 2 Aug 2021 18:20:02 +0800 Subject: [PATCH] =?UTF-8?q?=E6=94=B9=E5=90=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- HttpServer/Route/Node.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/HttpServer/Route/Node.php b/HttpServer/Route/Node.php index 7ff6cf6f..e66f649a 100644 --- a/HttpServer/Route/Node.php +++ b/HttpServer/Route/Node.php @@ -95,6 +95,7 @@ class Node extends HttpService } else { $this->handler = $handler; } + $this->setParameters($this->handler); return $this->injectMiddleware(); } @@ -118,7 +119,6 @@ class Node extends HttpService $this->handler[0], $this->handler[1], $this->createDispatch() ); } - $this->setParameters($this->handler); return $this; } @@ -130,7 +130,7 @@ class Node extends HttpService * @throws ReflectionException * @throws NotFindClassException */ - private function setParameters($handler) + public function setParameters($handler) { $container = Snowflake::getDi(); if ($handler instanceof Closure) {