mirror of
https://github.com/progval/Limnoria.git
synced 2025-04-26 13:01:06 -05:00
Simplify checkIgnored code from previous commit
This commit is contained in:
parent
d24130f46d
commit
903eceebda
11
src/ircdb.py
11
src/ircdb.py
@ -1180,15 +1180,14 @@ def checkIgnored(hostmask, recipient='', users=users, channels=channels):
|
|||||||
return True
|
return True
|
||||||
else:
|
else:
|
||||||
try:
|
try:
|
||||||
is_trusted = user._checkCapability('trusted')
|
if user._checkCapability('trusted'):
|
||||||
|
# Trusted users (including owners) shouldn't ever be ignored.
|
||||||
|
return False
|
||||||
except KeyError:
|
except KeyError:
|
||||||
# neither explicitly trusted or -trusted -> consider them not
|
# neither explicitly trusted or -trusted -> consider them not
|
||||||
# trusted
|
# trusted
|
||||||
is_trusted = False
|
pass
|
||||||
if is_trusted:
|
if user.ignore:
|
||||||
# Trusted users (including owners) shouldn't ever be ignored.
|
|
||||||
return False
|
|
||||||
elif user.ignore:
|
|
||||||
log.debug('Ignoring %s due to their IrcUser ignore flag.', hostmask)
|
log.debug('Ignoring %s due to their IrcUser ignore flag.', hostmask)
|
||||||
return True
|
return True
|
||||||
if ignores.checkIgnored(hostmask):
|
if ignores.checkIgnored(hostmask):
|
||||||
|
Loading…
x
Reference in New Issue
Block a user