diff --git a/PBot/BanTracker.pm b/PBot/BanTracker.pm index d0fa54a9..778177e1 100644 --- a/PBot/BanTracker.pm +++ b/PBot/BanTracker.pm @@ -64,6 +64,7 @@ sub get_baninfo { foreach my $channel (keys %{ $self->{banlist} }) { foreach my $banmask (keys %{ $self->{banlist}{$channel} }) { + my $banmask_key = $banmask; $banmask = quotemeta $banmask; $banmask =~ s/\\\*/.*?/g; @@ -71,8 +72,10 @@ sub get_baninfo { if($mask =~ m/$banmask/i) { my $baninfo = {}; + $baninfo->{banmask} = $banmask_key; $baninfo->{channel} = $channel; - $baninfo->{owner} = $self->{banlist}{$channel}[0]; + $baninfo->{owner} = $self->{banlist}{$channel}{$banmask_key}[0]; + $baninfo->{when} = $self->{banlist}{$channel}{$banmask_key}[1]; $self->{pbot}->logger->log("get-baninfo: dump: " . Dumper($baninfo) . "\n"); return $baninfo; } diff --git a/PBot/VERSION.pm b/PBot/VERSION.pm index 6b73c493..1cade59f 100644 --- a/PBot/VERSION.pm +++ b/PBot/VERSION.pm @@ -13,8 +13,8 @@ use warnings; # These are set automatically by the build/commit script use constant { BUILD_NAME => "PBot", - BUILD_REVISION => 320, - BUILD_DATE => "2011-02-14", + BUILD_REVISION => 321, + BUILD_DATE => "2011-02-17", }; 1;