mirror of
https://github.com/pragma-/pbot.git
synced 2024-12-24 19:52:34 +01:00
AntiSpam: Oops, inverted "unless" logic. Tricky, tricky "unless"!
This commit is contained in:
parent
a15da5a71b
commit
d10acb815b
@ -50,7 +50,7 @@ sub is_spam {
|
||||
|
||||
my $ret = eval {
|
||||
foreach my $space (keys %{ $self->{keywords}->hash }) {
|
||||
next unless not $all_namespaces and $namespace =~ m/^$space$/i;
|
||||
next unless $all_namespaces and $namespace =~ m/^$space$/i;
|
||||
foreach my $keyword (keys %{ $self->{keywords}->hash->{$space} }) {
|
||||
return 1 if $text =~ m/$keyword/i;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user