diff --git a/odoo/http.py b/odoo/http.py index e66497ccdba..a0da09bb795 100644 --- a/odoo/http.py +++ b/odoo/http.py @@ -1491,7 +1491,7 @@ def db_filter(dbs, httprequest=None): if odoo.tools.config['dbfilter']: r = odoo.tools.config['dbfilter'].replace('%h', h).replace('%d', d) dbs = [i for i in dbs if re.match(r, i)] - else: + elif odoo.tools.config['db_name']: # In case --db-filter is not provided and --database is passed, Odoo will # use the value of --database as a comma seperated list of exposed databases. exposed_dbs = set(db.strip() for db in odoo.tools.config['db_name'].split(','))