]> git.99rst.org Git - irssi-scripts.irssi.org.git/commitdiff
(quakequit) Handle joins properly so we can actually hide them.
authorphyber <redacted>
Tue, 3 Mar 2009 01:23:59 +0000 (01:23 +0000)
committerbw1 <redacted>
Sun, 14 Jan 2018 21:00:15 +0000 (22:00 +0100)
scripts/quakequit.pl

index fb511c561bdb4164a273b9da20494d8422558092..41008330730290ff62a7a54e35ef1ebd5067d8a6 100644 (file)
@@ -28,14 +28,15 @@ sub process_tag {
 
 # Process the 'message join' signal. (/JOIN)
 sub message_join {
-       my ($server_rec, $nick, $addr) = @_;
+       my ($server_rec, $channel, $nick, $addr) = @_;
        my $tag = $server_rec->{tag};
        # Return if we don't care about this tag.
        if (process_tag($tag) == 0) {
                return 0;
        }
+       #Irssi::print "Processing JOIN $tag: $nick $addr";
        # If the joining nick is in our quit hash, don't show the join.
-       if (defined $quits{$nick}) {
+       if ($quits{$nick} == 1) {
                delete $quits{$nick};
                Irssi::signal_stop();
                return 0;
@@ -50,6 +51,7 @@ sub message_quit {
        if (process_tag($tag) == 0) {
                return 0;
        }
+       #Irssi::print "Processing QUIT $tag: $nick $addr $reason";
        # If the quit message is registered, add the person to our quit hash and abort the signal.
        if ($reason eq "Registered") {
                $quits{$nick} = 1;
git clone https://git.99rst.org/PROJECT