From e9fc0e5474961cffcb1a588de3e83368c704fd75 Mon Sep 17 00:00:00 2001 From: Pragmatic Software Date: Fri, 31 May 2019 08:21:27 -0700 Subject: [PATCH] Factoids: add flag to prevent --keyword-override parsing --- PBot/Factoids.pm | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/PBot/Factoids.pm b/PBot/Factoids.pm index 74de16c1..861c5b19 100644 --- a/PBot/Factoids.pm +++ b/PBot/Factoids.pm @@ -1012,8 +1012,10 @@ sub handle_action { $stuff->{arguments} = ''; } - if ($command =~ s/\s*--keyword-override=([^ ]+)\s*//) { - $stuff->{keyword_override} = $1; + unless ($self->{factoids}->hash->{$channel}->{$keyword}->{'no_keyword_override'}) { + if ($command =~ s/\s*--keyword-override=([^ ]+)\s*//) { + $stuff->{keyword_override} = $1; + } } $stuff->{command} = $command;