diff --git a/PBot/Factoids.pm b/PBot/Factoids.pm index 98155ad6..a196ed71 100644 --- a/PBot/Factoids.pm +++ b/PBot/Factoids.pm @@ -158,7 +158,7 @@ sub export_factoids { sub find_factoid { my ($self, $from, $keyword, $arguments, $exact_channel, $exact_trigger) = @_; - $from = '.*' if not defined $from; + $from = '.*' if not defined $from or $from !~ /^#/; my $string = "$keyword" . (defined $arguments ? " $arguments" : ""); @@ -296,9 +296,7 @@ sub interpreter { $result =~ s/^/\/say $arguments: $keyword is / unless (defined $tonick); } } else { - if($result !~ /^\/.+? /) { - $result =~ s/^/\/say $keyword is / unless (defined $tonick); - } + return undef; } } } else { diff --git a/PBot/VERSION.pm b/PBot/VERSION.pm index 8c3ea136..7db0a0f6 100644 --- a/PBot/VERSION.pm +++ b/PBot/VERSION.pm @@ -13,7 +13,7 @@ use warnings; # These are set automatically by the build/commit script use constant { BUILD_NAME => "PBot", - BUILD_REVISION => 219, + BUILD_REVISION => 220, BUILD_DATE => "2010-06-29", };