mirror of
https://github.com/jlu5/PyLink.git
synced 2024-11-01 09:19:23 +01:00
relay: show secret channels in LINKED to those in the channel
Closes #278.
This commit is contained in:
parent
b79f391be6
commit
94f2422a1e
@ -1650,9 +1650,10 @@ def linked(irc, source, args):
|
|||||||
if remoteirc and channel in remoteirc.channels:
|
if remoteirc and channel in remoteirc.channels:
|
||||||
c = remoteirc.channels[channel]
|
c = remoteirc.channels[channel]
|
||||||
if ('s', None) in c.modes or ('p', None) in c.modes:
|
if ('s', None) in c.modes or ('p', None) in c.modes:
|
||||||
# Only show secret channels to opers, and tag them with
|
# Only show secret channels to opers or those in the channel, and tag them as
|
||||||
# [secret].
|
# [secret].
|
||||||
if irc.isOper(source):
|
localchan = getRemoteChan(remoteirc, irc, channel)
|
||||||
|
if irc.isOper(source) or (localchan and source in irc.channels[localchan].users):
|
||||||
s += '\x02[secret]\x02 '
|
s += '\x02[secret]\x02 '
|
||||||
else:
|
else:
|
||||||
continue
|
continue
|
||||||
|
Loading…
Reference in New Issue
Block a user