Revert part of previous commit. Return NotImplemented when object is not a valid JID

Signed-off-by: Maxime Buquet's avatarMaxime “pep” Buquet <>
parent 4e8800f9
...@@ -425,8 +425,8 @@ class JID: ...@@ -425,8 +425,8 @@ class JID:
if not isinstance(other, JID): if not isinstance(other, JID):
try: try:
other = JID(other) other = JID(other)
except: except InvalidJid:
return False return NotImplemented
return (self._node == other._node and return (self._node == other._node and
self._domain == other._domain and self._domain == other._domain and
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment