diff options
Diffstat (limited to 'modules')
| -rw-r--r-- | modules/command.pl | 5 | ||||
| -rw-r--r-- | modules/event.pl | 5 |
2 files changed, 7 insertions, 3 deletions
diff --git a/modules/command.pl b/modules/command.pl index 014e89b..dd270ea 100644 --- a/modules/command.pl +++ b/modules/command.pl @@ -28,7 +28,7 @@ sub command foreach my $command ( @{$::commands->{command}} ) { my $fail = 0; - unless ( (ASM::Util->speak($event->{to}->[0])) or (!ASM::Util->notRestricted($nick, "nocommands")) ) { + unless ( (ASM::Util->speak($event->{to}->[0])) ) { next unless (defined($command->{nohush}) && ($command->{nohush} eq "nohush")); } if (defined($command->{flag})) { #If the command is restricted, @@ -44,6 +44,9 @@ sub command } if ($cmd=~/$command->{cmd}/) { ASM::Util->dprint("$event->{from} told me: $cmd", "commander"); + if (!ASM::Util->notRestricted($nick, "nocommands")) { + $fail = 1 unless (defined($command->{nohush}) && ($command->{nohush} eq "nohush")); + } if ($fail == 1) { $conn->privmsg($nick, "You don't have permission to use that command, or you're not signed into nickserv."); } else { diff --git a/modules/event.pl b/modules/event.pl index 401a51d..eb9f70d 100644 --- a/modules/event.pl +++ b/modules/event.pl @@ -469,7 +469,8 @@ sub on_nick { sub on_kick { my ($conn, $event) = @_; if (lc $event->{to}->[0] eq lc $::settings->{nick}) { - $conn->join($event->{args}->[0]); + $conn->privmsg($::settings->{masterchan}, "I've been kicked from " . $event->{args}->[0] . ": " . $event->{args}->[1]); +# $conn->join($event->{args}->[0]); } my $nick = lc $event->{to}->[0]; my $chan = lc $event->{args}->[0]; @@ -679,7 +680,7 @@ sub checkRegged my $tgt = $chan; my $risk = "debug"; my $hilite=ASM::Util->commaAndify(ASM::Util->getAlert($tgt, $risk, 'hilights')); - my $txtz ="\x03" . $::RCOLOR{$::RISKS{$risk}} . "\u$risk\x03 risk threat [\x02$chan\x02] - channel appears to still be +r after 45 minutes; $hilite"; + my $txtz ="\x03" . $::RCOLOR{$::RISKS{$risk}} . "\u$risk\x03 risk threat [\x02$chan\x02] - channel appears to still be +r after 45 minutes; ping $hilite"; my @tgts = ASM::Util->getAlert($tgt, $risk, 'msgs'); ASM::Util->sendLongMsg($conn, \@tgts, $txtz) } |
