Reviewers: ,


Please review this at http://codereview.tryton.org/395002/

Affected files:
  M trytond/model/browse.py


Index: trytond/model/browse.py
===================================================================
--- a/trytond/model/browse.py
+++ b/trytond/model/browse.py
@@ -244,9 +244,13 @@
         return "BrowseRecord(%s, %d)" % (self._model_name, self.id)

     def __eq__(self, other):
+        if not isinstance(other, BrowseRecord):
+            return False
         return (self._model_name, self.id) == (other._model_name, other.id)

     def __ne__(self, other):
+        if not isinstance(other, BrowseRecord):
+            return True
         return (self._model_name, self.id) != (other._model_name, other.id)

# we need to define __unicode__ even though we've already defined __str__


--
[email protected] mailing list

Reply via email to