Fix previous commit on some Python versions.

This commit is contained in:
Valentin Lorentz 2016-09-20 23:09:29 +02:00
parent d39647142c
commit 2cfe0f679f

View File

@ -386,8 +386,12 @@ class RSS(callbacks.Plugin):
blacklist = self.registryValue('keywordBlacklist', channel) blacklist = self.registryValue('keywordBlacklist', channel)
# fix shadowing by “from supybot.commands import *” # fix shadowing by “from supybot.commands import *”
all = __builtins__.all try:
any = __builtins__.any all = __builtins__.all
any = __builtins__.any
except AttributeError:
all = __builtins__['all']
any = __builtins__['any']
if whitelist: if whitelist:
if all(kw not in entry.title and kw not in entry.description if all(kw not in entry.title and kw not in entry.description