3
0
mirror of https://github.com/pragma-/pbot.git synced 2024-10-04 18:38:47 +02:00

Remove extraneous debug logging statements

This commit is contained in:
Pragmatic Software 2014-04-19 10:34:21 +00:00
parent f003ff1178
commit b3ab3bae8f
2 changed files with 2 additions and 5 deletions

View File

@ -140,8 +140,7 @@ sub check_ignore {
if(defined $channel) { # do not execute following if text is coming from STDIN ($channel undef)
if($channel =~ /^#/) {
$self->{ignore_flood_counter}->{$channel}++; # TODO: make this per channel, e.g., ${ $self->{ignore_flood_counter} }{$channel}++
$pbot->logger->log("flood_msg: $self->{ignore_flood_counter}->{$channel}\n");
$self->{ignore_flood_counter}->{$channel}++;
}
if(not exists $self->{last_timestamp}->{$channel}) {
@ -150,12 +149,10 @@ sub check_ignore {
$self->{last_timestamp}->{$channel} = $now;
if(exists $self->{ignore_flood_counter}->{$channel} and $self->{ignore_flood_counter}->{$channel} > 0) {
$self->{ignore_flood_counter}->{$channel} = 0;
$pbot->logger->log("flood_msg reset\n");
}
}
if(exists $self->{ignore_flood_counter}->{$channel} and $self->{ignore_flood_counter}->{$channel} > 5) {
$pbot->logger->log("flood_msg exceeded! [$self->{ignore_flood_counter}->{$channel}]\n");
$self->{pbot}->{ignorelistcmds}->ignore_user("", "floodcontrol", "", "", ".* $channel 300");
$self->{ignore_flood_counter}->{$channel} = 0;
if($channel =~ /^#/) {

View File

@ -13,7 +13,7 @@ use warnings;
# These are set automatically by the build/commit script
use constant {
BUILD_NAME => "PBot",
BUILD_REVISION => 544,
BUILD_REVISION => 545,
BUILD_DATE => "2014-04-19",
};