fix: 修复自动路由为null时错误

This commit is contained in:
Ying
2023-07-03 20:41:27 +08:00
parent a5d9b9db7f
commit 35407bd4a3

View File

@@ -74,7 +74,9 @@ foreach ($pluginList as $item) {
if (!$item['status']) {
continue;
}
foreach ($item['rewrite'] as $route => $value) {
$routeList = $item['rewrite'] ?? [];
foreach ($routeList as $route => $value) {
$separator = explode('/', $value);
$method = end($separator);
array_pop($separator);