Use re.search, not re.match, for command.regex hooks
This commit is contained in:
parent
7ccfa12b00
commit
8be178f406
1 changed files with 1 additions and 1 deletions
|
@ -242,7 +242,7 @@ class Module(ModuleManager.BaseModule):
|
||||||
pattern = utils.http.REGEX_URL
|
pattern = utils.http.REGEX_URL
|
||||||
|
|
||||||
if pattern:
|
if pattern:
|
||||||
match = re.match(pattern, event["message"])
|
match = re.search(pattern, event["message"])
|
||||||
if match:
|
if match:
|
||||||
command = hook.get_kwarg("command", "")
|
command = hook.get_kwarg("command", "")
|
||||||
res = self.command(event["server"], event["channel"],
|
res = self.command(event["server"], event["channel"],
|
||||||
|
|
Loading…
Reference in a new issue