改名
This commit is contained in:
@@ -86,7 +86,6 @@ class Middleware
|
|||||||
$node->addAfter($attribute->after);
|
$node->addAfter($attribute->after);
|
||||||
}
|
}
|
||||||
if ($attribute instanceof RMiddleware) {
|
if ($attribute instanceof RMiddleware) {
|
||||||
var_dump($attribute->middleware);
|
|
||||||
$node->addMiddleware($attribute->middleware);
|
$node->addMiddleware($attribute->middleware);
|
||||||
}
|
}
|
||||||
if ($attribute instanceof Limits) {
|
if ($attribute instanceof Limits) {
|
||||||
@@ -105,7 +104,7 @@ class Middleware
|
|||||||
{
|
{
|
||||||
$middleWares = $this->annotation_limit($node);
|
$middleWares = $this->annotation_limit($node);
|
||||||
$middleWares = $this->annotation_interceptor($node, $middleWares);
|
$middleWares = $this->annotation_interceptor($node, $middleWares);
|
||||||
foreach ($this->middleWares as $middleWare) {
|
foreach ($node->getMiddleWares() as $middleWare) {
|
||||||
$middleWares[] = $middleWare;
|
$middleWares[] = $middleWare;
|
||||||
}
|
}
|
||||||
$this->middleWares = [];
|
$this->middleWares = [];
|
||||||
|
|||||||
@@ -408,6 +408,15 @@ class Node extends Application
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @return array
|
||||||
|
*/
|
||||||
|
public function getMiddleWares(): array
|
||||||
|
{
|
||||||
|
return $this->middleware;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @throws Exception
|
* @throws Exception
|
||||||
*/
|
*/
|
||||||
@@ -418,7 +427,6 @@ class Node extends Application
|
|||||||
}
|
}
|
||||||
/** @var Middleware $made */
|
/** @var Middleware $made */
|
||||||
$made = Snowflake::createObject(Middleware::class);
|
$made = Snowflake::createObject(Middleware::class);
|
||||||
$made->setMiddleWares($this->middleware);
|
|
||||||
$made->getGenerate($this);
|
$made->getGenerate($this);
|
||||||
return $this;
|
return $this;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user