mirror of
https://github.com/zhamao-robot/zhamao-framework.git
synced 2026-07-24 17:15:36 +08:00
fix BotCommand regex match argument bug
This commit is contained in:
@@ -464,6 +464,7 @@ class OneBot12Adapter extends ZMPlugin
|
|||||||
}
|
}
|
||||||
// 测试 regex
|
// 测试 regex
|
||||||
if ($v->regex !== '' && preg_match('/' . $v->regex . '/u', $full_str, $match) !== 0) {
|
if ($v->regex !== '' && preg_match('/' . $v->regex . '/u', $full_str, $match) !== 0) {
|
||||||
|
array_shift($match);
|
||||||
return [$v, $match, $full_str];
|
return [$v, $match, $full_str];
|
||||||
}
|
}
|
||||||
// 测试 start_with
|
// 测试 start_with
|
||||||
|
|||||||
Reference in New Issue
Block a user