diff --git a/sopel_modules/SpiceBot/Sherlock.py b/sopel_modules/SpiceBot/Sherlock.py index d99e0f1..5f7f6f0 100644 --- a/sopel_modules/SpiceBot/Sherlock.py +++ b/sopel_modules/SpiceBot/Sherlock.py @@ -68,10 +68,10 @@ class Sherlock(): if error not in r.url: user_exists = True - if username not in list(self.dict[social_network]["cache"].keys()): - self.dict[social_network]["cache"][username] = {} - self.dict[social_network]["cache"][username]["time"] = time.time() - self.dict[social_network]["cache"][username]["exists"] = user_exists + self.dict[social_network]["cache"][username] = { + "time": time.time(), + "exists": user_exists + } if user_exists: return True