Send PING and PONG as 'immediate' lines

This commit is contained in:
jesopo 2019-06-04 14:31:21 +01:00
parent 4a4d0a37d7
commit 3ac01197f2

View file

@ -307,9 +307,9 @@ class Server(IRCObject.Object):
return self.send(utils.irc.protocol.password(password))
def send_ping(self, nonce: str="hello") -> IRCLine.SentLine:
return self.send(utils.irc.protocol.ping(nonce))
return self.send(utils.irc.protocol.ping(nonce), immediate=True)
def send_pong(self, nonce: str="hello") -> IRCLine.SentLine:
return self.send(utils.irc.protocol.pong(nonce))
return self.send(utils.irc.protocol.pong(nonce), immediate=True)
def try_rejoin(self, event: EventManager.Event):
if event["server_id"] == self.id and event["channel_name"