[FIX] res.users: context_get cache was not cleared properly, due to braindead impleme...
authorOlivier Dony <odo@openerp.com>
Wed, 19 Dec 2012 10:13:15 +0000 (11:13 +0100)
committerOlivier Dony <odo@openerp.com>
Wed, 19 Dec 2012 10:13:15 +0000 (11:13 +0100)
Discarding the cache completely is suboptimal but
makes the code simpler, and this is not performance
critical anyway. The cache is mostly useful during
module installation, which involves no call to clear_cache.

bzr revid: odo@openerp.com-20121219101315-1ccuwm6nvmov12zv

openerp/addons/base/res/res_users.py

index a2301ce..df83f0a 100644 (file)
@@ -299,8 +299,7 @@ class res_users(osv.osv):
             for id in ids:
                 if id in self._uid_cache[db]:
                     del self._uid_cache[db][id]
-        self.context_get.clear_cache(self, cr)
-
+        self.context_get.clear_cache(self)
         return res
 
     def unlink(self, cr, uid, ids, context=None):