This commit is contained in:
xl
2023-06-28 15:23:05 +08:00
parent ef6449a3b0
commit 4b975b570b
+1 -3
View File
@@ -63,11 +63,9 @@ class RouterCollector implements \ArrayAccess, \IteratorAggregate
* @var HashMap $handlers
*/
foreach ($this->methods as $method => $handler) {
[$method, $path] = explode('_', $method);
$middleware = $middlewareManager->get($handler->getClass(), $handler->getMethod());
$handlers->put($path, new HttpRequestHandler($middleware, $handler));
$this->methods[$method] = new HttpRequestHandler($middleware, $handler);
}
}