1
This commit is contained in:
@@ -246,6 +246,9 @@ if (!function_exists('injectRuntime')) {
|
|||||||
$router = [];
|
$router = [];
|
||||||
foreach ($fileLists as $class) {
|
foreach ($fileLists as $class) {
|
||||||
foreach (NoteManager::getTargetNote($class) as $value) {
|
foreach (NoteManager::getTargetNote($class) as $value) {
|
||||||
|
if (!method_exists($value, 'execute')){
|
||||||
|
continue;
|
||||||
|
}
|
||||||
$value->execute($class);
|
$value->execute($class);
|
||||||
}
|
}
|
||||||
$methods = $di->getMethodAttribute($class);
|
$methods = $di->getMethodAttribute($class);
|
||||||
@@ -257,6 +260,9 @@ if (!function_exists('injectRuntime')) {
|
|||||||
if ($item instanceof Route) {
|
if ($item instanceof Route) {
|
||||||
$router[] = [$item, $class, $method];
|
$router[] = [$item, $class, $method];
|
||||||
} else {
|
} else {
|
||||||
|
if (!method_exists($item, 'execute')){
|
||||||
|
continue;
|
||||||
|
}
|
||||||
$item->execute($class, $method);
|
$item->execute($class, $method);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -265,6 +271,9 @@ if (!function_exists('injectRuntime')) {
|
|||||||
if (!empty($router)) {
|
if (!empty($router)) {
|
||||||
foreach ($router as $class) {
|
foreach ($router as $class) {
|
||||||
[$item, $class, $method] = $class;
|
[$item, $class, $method] = $class;
|
||||||
|
if (!method_exists($item, 'execute')){
|
||||||
|
continue;
|
||||||
|
}
|
||||||
$item->execute($class, $method);
|
$item->execute($class, $method);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user