Allow users.get(..., allow_multiple=True) to return an empty list

This commit is contained in:
Vgr E. Barry 2016-11-21 21:12:27 -05:00
parent d590e7b727
commit ea51642240

View File

@ -70,7 +70,7 @@ def _get(nick=None, ident=None, host=None, realname=None, account=None, *, allow
raise ValueError("More than one user matches: " +
_arg_msg.format(nick, ident, host, realname, account, allow_bot))
if not potential and not allow_none:
if not potential and not allow_multiple and not allow_none:
raise KeyError(_arg_msg.format(nick, ident, host, realname, account, allow_bot))
if allow_multiple: