[FIX] core: int() deprecation warning
__int__ should always return an integer, not a bool and not a completely unrelated type either.
This commit is contained in:
+1
-1
@@ -5625,7 +5625,7 @@ Record ids: %(records)s
|
||||
return set(self._ids) >= set(other._ids)
|
||||
|
||||
def __int__(self):
|
||||
return self.id
|
||||
return self.id or 0
|
||||
|
||||
def __str__(self):
|
||||
return "%s%s" % (self._name, getattr(self, '_ids', ""))
|
||||
|
||||
Reference in New Issue
Block a user