Use unicode.lower instead of str.lower for ACLs
This commit is contained in:
parent
fcffce45f3
commit
e237e6d854
|
@ -30,11 +30,11 @@ def sieve_suite(bot, input, func, args):
|
||||||
acl = bot.config.get('acls', {}).get(func.__name__)
|
acl = bot.config.get('acls', {}).get(func.__name__)
|
||||||
if acl:
|
if acl:
|
||||||
if 'deny-except' in acl:
|
if 'deny-except' in acl:
|
||||||
allowed_channels = map(str.lower, acl['deny-except'])
|
allowed_channels = map(unicode.lower, acl['deny-except'])
|
||||||
if input.chan.lower() not in allowed_channels:
|
if input.chan.lower() not in allowed_channels:
|
||||||
return None
|
return None
|
||||||
if 'allow-except' in acl:
|
if 'allow-except' in acl:
|
||||||
denied_channels = map(str.lower, acl['allow-except'])
|
denied_channels = map(unicode.lower, acl['allow-except'])
|
||||||
if input.chan.lower() in denied_channels:
|
if input.chan.lower() in denied_channels:
|
||||||
return None
|
return None
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue