jid: return not equal if value can't be converted to JID
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
This commit is contained in:
parent
40053518aa
commit
4e8800f954
1 changed files with 4 additions and 1 deletions
|
@ -423,7 +423,10 @@ class JID:
|
|||
if isinstance(other, UnescapedJID):
|
||||
return False
|
||||
if not isinstance(other, JID):
|
||||
other = JID(other)
|
||||
try:
|
||||
other = JID(other)
|
||||
except:
|
||||
return False
|
||||
|
||||
return (self._node == other._node and
|
||||
self._domain == other._domain and
|
||||
|
|
Loading…
Reference in a new issue