diff options
Diffstat (limited to 'odoo/tools')
| -rw-r--r-- | odoo/tools/cache.py | 4 | ||||
| -rw-r--r-- | odoo/tools/sql.py | 1 |
2 files changed, 1 insertions, 4 deletions
diff --git a/odoo/tools/cache.py b/odoo/tools/cache.py index 3703fc83ab1..48dc42ba04c 100644 --- a/odoo/tools/cache.py +++ b/odoo/tools/cache.py @@ -92,9 +92,7 @@ class ormcache(object): def clear(self, model, *args): """ Clear the registry cache """ - d, key0, _ = self.lru(model) - d.clear() - model.pool.cache_cleared = True + model.pool._clear_cache() class ormcache_context(ormcache): diff --git a/odoo/tools/sql.py b/odoo/tools/sql.py index c4e9a143a8e..563ed08c679 100644 --- a/odoo/tools/sql.py +++ b/odoo/tools/sql.py @@ -189,7 +189,6 @@ def drop_index(cr, indexname, tablename): def drop_view_if_exists(cr, viewname): cr.execute("DROP view IF EXISTS %s CASCADE" % (viewname,)) - cr.commit() def escape_psql(to_escape): return to_escape.replace('\\', r'\\').replace('%', '\%').replace('_', '\_') |
