Fixed inheritance.

This commit is contained in:
flash 2024-03-28 20:19:54 +00:00
parent 8a5059c7ec
commit bcc7e8066a
2 changed files with 3 additions and 2 deletions

View file

@ -1 +1 @@
0.2403.282016
0.2403.282019

View file

@ -6,6 +6,7 @@
namespace Index\Http\Routing;
use Attribute;
use ReflectionAttribute;
use ReflectionObject;
/**
@ -35,7 +36,7 @@ class HandlerAttribute {
$methodInfos = $objectInfo->getMethods();
foreach($methodInfos as $methodInfo) {
$attrInfos = $methodInfo->getAttributes(HandlerAttribute::class);
$attrInfos = $methodInfo->getAttributes(HandlerAttribute::class, ReflectionAttribute::IS_INSTANCEOF);
foreach($attrInfos as $attrInfo) {
$handlerInfo = $attrInfo->newInstance();