mirror of
https://github.com/moparisthebest/Yaaic
synced 2024-11-22 17:02:21 -05:00
Pircbot Patch: Call onQuit() before removing the user. Otherwise we do not know which channels the user was on
This commit is contained in:
parent
7ee8984f9a
commit
608ea2e614
@ -1026,13 +1026,17 @@ public abstract class PircBot implements ReplyConstants {
|
|||||||
}
|
}
|
||||||
else if (command.equals("QUIT")) {
|
else if (command.equals("QUIT")) {
|
||||||
// Someone has quit from the IRC server.
|
// Someone has quit from the IRC server.
|
||||||
|
|
||||||
|
// XXX: Pircbot Patch - Call onQuit before removing the user. This way we
|
||||||
|
// are able to know which channels the user was on.
|
||||||
|
this.onQuit(sourceNick, sourceLogin, sourceHostname, line.substring(line.indexOf(" :") + 2));
|
||||||
|
|
||||||
if (sourceNick.equals(this.getNick())) {
|
if (sourceNick.equals(this.getNick())) {
|
||||||
this.removeAllChannels();
|
this.removeAllChannels();
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
this.removeUser(sourceNick);
|
this.removeUser(sourceNick);
|
||||||
}
|
}
|
||||||
this.onQuit(sourceNick, sourceLogin, sourceHostname, line.substring(line.indexOf(" :") + 2));
|
|
||||||
}
|
}
|
||||||
else if (command.equals("KICK")) {
|
else if (command.equals("KICK")) {
|
||||||
// Somebody has been kicked from a channel.
|
// Somebody has been kicked from a channel.
|
||||||
|
Loading…
Reference in New Issue
Block a user