[FIX] base_suspend_security: Reuse existing suspended envs

This commit is contained in:
Holger Brunn
2021-02-12 10:37:46 +01:00
parent f70b2f5ede
commit d6a99cabc3
2 changed files with 12 additions and 0 deletions

View File

@@ -5,6 +5,8 @@ from odoo.tools import pycompat
class BaseSuspendSecurityUid(int):
def __eq__(self, other):
if isinstance(other, BaseSuspendSecurityUid):
return self * 1 == other * 1
if isinstance(other, pycompat.integer_types):
return False
return super(BaseSuspendSecurityUid, self).__int__() == other