summaryrefslogtreecommitdiff
path: root/odoo/modules/registry.py
diff options
context:
space:
mode:
Diffstat (limited to 'odoo/modules/registry.py')
-rw-r--r--odoo/modules/registry.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/odoo/modules/registry.py b/odoo/modules/registry.py
index 1126b05e82a..8ccb1615113 100644
--- a/odoo/modules/registry.py
+++ b/odoo/modules/registry.py
@@ -491,7 +491,11 @@ class Registry(Mapping):
Verify that all tables are present and try to initialize those that are missing.
"""
env = odoo.api.Environment(cr, SUPERUSER_ID, {})
- table2model = {model._table: name for name, model in env.items() if not model._abstract}
+ table2model = {
+ model._table: name
+ for name, model in env.items()
+ if not model._abstract and model.__class__._table_query is None
+ }
missing_tables = set(table2model).difference(existing_tables(cr, table2model))
if missing_tables: