mirror of
https://github.com/Mikaela/Limnoria.git
synced 2025-02-17 06:00:42 +01:00
Add identified status and away message to Relay.whois
This commit is contained in:
parent
03aad1712a
commit
8fe7d7e4e8
@ -394,9 +394,11 @@ class Relay(callbacks.Privmsg, configurable.Mixin):
|
|||||||
else:
|
else:
|
||||||
self._whois[(irc, nick)][-1][msg.command] = msg
|
self._whois[(irc, nick)][-1][msg.command] = msg
|
||||||
|
|
||||||
|
do301 = do311
|
||||||
do312 = do311
|
do312 = do311
|
||||||
do317 = do311
|
do317 = do311
|
||||||
do319 = do311
|
do319 = do311
|
||||||
|
do320 = do311
|
||||||
|
|
||||||
def do318(self, irc, msg):
|
def do318(self, irc, msg):
|
||||||
if not isinstance(irc, irclib.Irc):
|
if not isinstance(irc, irclib.Irc):
|
||||||
@ -447,8 +449,20 @@ class Relay(callbacks.Privmsg, configurable.Mixin):
|
|||||||
server = d['312'].args[2]
|
server = d['312'].args[2]
|
||||||
else:
|
else:
|
||||||
server = '<unknown>'
|
server = '<unknown>'
|
||||||
s = '%s (%s) has been on server %s since %s (idle for %s) and %s.' % \
|
if '301' in d:
|
||||||
(user, hostmask, server, signon, idle, channels)
|
away = ' %s is away: %s.' % (user, d['301'].args[2])
|
||||||
|
else:
|
||||||
|
away = ''
|
||||||
|
if '320' in d:
|
||||||
|
if d['320'].args[2]:
|
||||||
|
identify = ' identified'
|
||||||
|
else:
|
||||||
|
identify = ''
|
||||||
|
else:
|
||||||
|
identify = ''
|
||||||
|
s = '%s (%s) has been%s on server %s since %s (idle for %s) and '\
|
||||||
|
'%s.%s' % (user, hostmask, identify, server, signon, idle,
|
||||||
|
channels, away)
|
||||||
replyIrc.reply(replyMsg, s)
|
replyIrc.reply(replyMsg, s)
|
||||||
del self._whois[(irc, nick)]
|
del self._whois[(irc, nick)]
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user