3
0
mirror of https://github.com/pragma-/pbot.git synced 2024-11-23 04:19:27 +01:00

Restore immediately functionality to unban/unmute

This commit is contained in:
Pragmatic Software 2017-08-03 23:19:02 -07:00
parent 1dcbcef14a
commit 53c6177801
2 changed files with 6 additions and 6 deletions

View File

@ -112,7 +112,7 @@ sub unban_user {
return "/msg $nick Usage for /msg: unban <nick/mask> <channel>" if $channel !~ /^#/;
$self->{pbot}->{chanops}->unban_user($target, $channel);
$self->{pbot}->{chanops}->unban_user($target, $channel, 1);
return "/msg $nick $target has been unbanned from $channel.";
}
@ -187,7 +187,7 @@ sub unmute_user {
return "/msg $nick Usage for /msg: unmute <mask> <channel>" if $channel !~ /^#/;
$self->{pbot}->{chanops}->unmute_user($target, $channel);
$self->{pbot}->{chanops}->unmute_user($target, $channel, 1);
return "/msg $nick $target has been unmuted in $channel.";
}

View File

@ -128,7 +128,7 @@ sub ban_user {
sub unban_user {
my $self = shift;
my ($mask, $channel) = @_;
my ($mask, $channel, $immediately) = @_;
my $bans;
@ -168,7 +168,7 @@ sub unban_user {
$unbanned{$baninfo->{banmask}} = 1;
$self->add_to_unban_queue($channel, 'b', $baninfo->{banmask});
}
$self->check_unban_queue;
$self->check_unban_queue if $immediately;
}
sub ban_user_timed {
@ -214,7 +214,7 @@ sub mute_user {
sub unmute_user {
my $self = shift;
my ($mask, $channel) = @_;
my ($mask, $channel, $immediately) = @_;
$mask = lc $mask;
$channel = lc $channel;
$self->{pbot}->{logger}->log("Unmuting $channel $mask\n");
@ -225,7 +225,7 @@ sub unmute_user {
}
$self->add_to_unban_queue($channel, 'q', $mask);
$self->check_unban_queue;
$self->check_unban_queue if $immediately;
}
sub mute_user_timed {