3
0
mirror of https://github.com/jlu5/PyLink.git synced 2024-11-01 01:09:22 +01:00

utils: fix irc.users changing size during lookup

This commit is contained in:
James Lu 2015-12-11 18:43:58 -08:00
parent f79524e9e1
commit 31c47b50f3

View File

@ -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