mirror of
https://github.com/pragma-/pbot.git
synced 2024-12-22 18:52:40 +01:00
Temporary hack to skip hostmask entry when iterating channels in message history, will fix soon
This commit is contained in:
parent
8a5c7a99c2
commit
49bbf5c73e
@ -182,6 +182,8 @@ sub prune_message_history {
|
||||
foreach my $nick (keys %{ $self->{message_history} }) {
|
||||
foreach my $channel (keys %{ $self->{message_history}->{$nick} })
|
||||
{
|
||||
next if $channel eq 'hostmask'; # TODO: move channels into {channel} subkey
|
||||
|
||||
#$self->{pbot}->logger->log("Checking [$nick][$channel]\n");
|
||||
my $length = $#{ $self->{message_history}->{$nick}{$channel}{messages} } + 1;
|
||||
my %last = %{ @{ $self->{message_history}->{$nick}{$channel}{messages} }[$length - 1] };
|
||||
|
@ -79,6 +79,7 @@ sub list {
|
||||
foreach my $history_nick (keys %{ $self->{pbot}->antiflood->message_history }) {
|
||||
if($history_nick =~ m/$nick_search/i) {
|
||||
foreach my $history_channel (keys %{ $self->{pbot}->antiflood->message_history->{$history_nick} }) {
|
||||
next if $history_channel eq 'hostmask'; # TODO: move channels into {channel} subkey
|
||||
if($history_channel =~ m/$channel_search/i) {
|
||||
my @messages = @{ ${ $self->{pbot}->antiflood->message_history }{$history_nick}{$history_channel}{messages} };
|
||||
|
||||
|
@ -13,8 +13,8 @@ use warnings;
|
||||
# These are set automatically by the build/commit script
|
||||
use constant {
|
||||
BUILD_NAME => "PBot",
|
||||
BUILD_REVISION => 150,
|
||||
BUILD_DATE => "2010-06-05",
|
||||
BUILD_REVISION => 151,
|
||||
BUILD_DATE => "2010-06-06",
|
||||
};
|
||||
|
||||
1;
|
||||
|
Loading…
Reference in New Issue
Block a user