mirror of
https://github.com/jlu5/PyLink.git
synced 2024-12-18 08:02:51 +01:00
unreal: implicitly set +xt when SETHOST or CHGHOST is received (#136)
This commit is contained in:
parent
adcb61da67
commit
9a43a620f9
@ -746,6 +746,11 @@ class UnrealProtocol(TS6BaseProtocol):
|
|||||||
"""Handles CHGHOST, used for self hostname changes."""
|
"""Handles CHGHOST, used for self hostname changes."""
|
||||||
# <- :70MAAAAAB SETIDENT some.host
|
# <- :70MAAAAAB SETIDENT some.host
|
||||||
self.irc.users[numeric].host = newhost = args[0]
|
self.irc.users[numeric].host = newhost = args[0]
|
||||||
|
|
||||||
|
# When SETHOST or CHGHOST is used, modes +xt are implicitly set on the
|
||||||
|
# target.
|
||||||
|
utils.applyModes(self.irc, numeric, [('+x', None), ('+t', None)])
|
||||||
|
|
||||||
return {'target': numeric, 'newhost': newhost}
|
return {'target': numeric, 'newhost': newhost}
|
||||||
|
|
||||||
def handle_setname(self, numeric, command, args):
|
def handle_setname(self, numeric, command, args):
|
||||||
@ -766,6 +771,11 @@ class UnrealProtocol(TS6BaseProtocol):
|
|||||||
# <- :GL CHGHOST GL some.host
|
# <- :GL CHGHOST GL some.host
|
||||||
target = self._getNick(args[0])
|
target = self._getNick(args[0])
|
||||||
self.irc.users[target].host = newhost = args[1]
|
self.irc.users[target].host = newhost = args[1]
|
||||||
|
|
||||||
|
# When SETHOST or CHGHOST is used, modes +xt are implicitly set on the
|
||||||
|
# target.
|
||||||
|
utils.applyModes(self.irc, target, [('+x', None), ('+t', None)])
|
||||||
|
|
||||||
return {'target': target, 'newhost': newhost}
|
return {'target': target, 'newhost': newhost}
|
||||||
|
|
||||||
def handle_chgname(self, numeric, command, args):
|
def handle_chgname(self, numeric, command, args):
|
||||||
|
Loading…
Reference in New Issue
Block a user