From 31c47b50f3d14a836216e29ee04681c12aeb61aa Mon Sep 17 00:00:00 2001 From: James Lu Date: Fri, 11 Dec 2015 18:43:58 -0800 Subject: [PATCH] utils: fix irc.users changing size during lookup --- utils.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/utils.py b/utils.py index 0c171ea..d62b4de 100644 --- a/utils.py +++ b/utils.py @@ -138,7 +138,7 @@ def toLower(irc, text): def nickToUid(irc, nick): """Returns the UID of a user named nick, if present.""" nick = toLower(irc, nick) - for k, v in irc.users.items(): + for k, v in irc.users.copy().items(): if toLower(irc, v.nick) == nick: return k