mirror of
https://github.com/nonebot/nonebot2.git
synced 2025-07-28 16:51:26 +00:00
Fix a bug
This commit is contained in:
@ -25,7 +25,7 @@ def parse_potential_commands(sentence):
|
||||
processed = False
|
||||
for regex in processor[0]:
|
||||
for word, flag in segmentation:
|
||||
if re.match(regex, word):
|
||||
if re.search(regex, word):
|
||||
result = processor[1](sentence, segmentation)
|
||||
if result:
|
||||
potential_commands.append(result)
|
||||
|
Reference in New Issue
Block a user