restricted zapp brannigan goodie to m/quote/

master
Dylan Lloyd 2012-06-11 15:53:55 -04:00
parent b99ec47aa0
commit d79a25660e
1 changed files with 1 additions and 0 deletions

View File

@ -7,6 +7,7 @@ triggers any => "zapp", "brannigan";
zci is_cached => 0;
handle query => sub {
return if $_ !~ m/quote/;
my @quotes = share('quotes.txt')->slurp;
my $rand = int(rand(scalar(@quotes)));
my $quote = $quotes[$rand];