mirror of
https://github.com/Mikaela/Limnoria.git
synced 2025-01-24 02:54:05 +01:00
ircutils: add $network to standard substitutions
This commit is contained in:
parent
1d62a0a7c5
commit
1b0c2ab95a
@ -824,6 +824,7 @@ def standardSubstitute(irc, msg, text, env=None):
|
|||||||
if irc:
|
if irc:
|
||||||
vars.update({
|
vars.update({
|
||||||
'botnick': irc.nick,
|
'botnick': irc.nick,
|
||||||
|
'network': irc.network,
|
||||||
})
|
})
|
||||||
|
|
||||||
if msg:
|
if msg:
|
||||||
|
@ -219,6 +219,8 @@ class FunctionsTestCase(SupyTestCase):
|
|||||||
msg = ircmsgs.IrcMsg(':%s PRIVMSG #channel :stuff' % self.hostmask)
|
msg = ircmsgs.IrcMsg(':%s PRIVMSG #channel :stuff' % self.hostmask)
|
||||||
class Irc(object):
|
class Irc(object):
|
||||||
nick = 'bob'
|
nick = 'bob'
|
||||||
|
network = 'testnet'
|
||||||
|
|
||||||
irc = Irc()
|
irc = Irc()
|
||||||
|
|
||||||
f = ircutils.standardSubstitute
|
f = ircutils.standardSubstitute
|
||||||
|
Loading…
Reference in New Issue
Block a user