mirror of
https://github.com/pragma-/pbot.git
synced 2024-11-23 04:19:27 +01:00
Add silent
parameter to prevent logging of ignored messages
This commit is contained in:
parent
d344e6d667
commit
99e505b811
@ -131,7 +131,7 @@ sub save_ignores {
|
||||
|
||||
sub check_ignore {
|
||||
my $self = shift;
|
||||
my ($nick, $user, $host, $channel) = @_;
|
||||
my ($nick, $user, $host, $channel, $silent) = @_;
|
||||
my $pbot = $self->{pbot};
|
||||
$channel = lc $channel;
|
||||
|
||||
@ -175,7 +175,7 @@ sub check_ignore {
|
||||
$ignored_escaped =~ s/\\(\.|\*)/$1/g;
|
||||
|
||||
if(($channel =~ /$ignored_channel_escaped/i) && ($hostmask =~ /$ignored_escaped/i)) {
|
||||
$self->{pbot}->{logger}->log("$nick!$user\@$host message ignored in channel $channel (matches [$ignored] host and [$ignored_channel] channel)\n");
|
||||
$self->{pbot}->{logger}->log("$nick!$user\@$host message ignored in channel $channel (matches [$ignored] host and [$ignored_channel] channel)\n") unless $silent;
|
||||
return 1;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user