改名
This commit is contained in:
@@ -5,7 +5,7 @@ declare(strict_types=1);
|
|||||||
namespace HttpServer\Route;
|
namespace HttpServer\Route;
|
||||||
|
|
||||||
|
|
||||||
use Annotation\Route\Middleware as RMiddleware;
|
use Annotation\Route\Middleware;
|
||||||
use Closure;
|
use Closure;
|
||||||
use HttpServer\Abstracts\HttpService;
|
use HttpServer\Abstracts\HttpService;
|
||||||
use HttpServer\Http\Request;
|
use HttpServer\Http\Request;
|
||||||
@@ -331,7 +331,7 @@ class Node extends HttpService
|
|||||||
if ($attribute instanceof \Annotation\Route\After) {
|
if ($attribute instanceof \Annotation\Route\After) {
|
||||||
$node->addAfter($attribute->after);
|
$node->addAfter($attribute->after);
|
||||||
}
|
}
|
||||||
if ($attribute instanceof RMiddleware) {
|
if ($attribute instanceof Middleware) {
|
||||||
$node->addMiddleware($attribute->middleware);
|
$node->addMiddleware($attribute->middleware);
|
||||||
}
|
}
|
||||||
if ($attribute instanceof \Annotation\Route\Limits) {
|
if ($attribute instanceof \Annotation\Route\Limits) {
|
||||||
@@ -512,6 +512,9 @@ class Node extends HttpService
|
|||||||
if (is_string($closure)) {
|
if (is_string($closure)) {
|
||||||
$closure = [Snowflake::createObject($closure), 'onHandler'];
|
$closure = [Snowflake::createObject($closure), 'onHandler'];
|
||||||
}
|
}
|
||||||
|
if (str_contains($this->path, 'switch/map')) {
|
||||||
|
var_dump($closure);
|
||||||
|
}
|
||||||
if (in_array($closure, $this->middleware)) {
|
if (in_array($closure, $this->middleware)) {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user