From 14245e24fc3fd43f111d445cc0526232a442acab Mon Sep 17 00:00:00 2001 From: Antony Lesuisse Date: Sun, 10 Nov 2013 02:04:11 +0100 Subject: [PATCH] [FIX] /web always save the provided db in session guessed_db is only computed by the /web controller, so even if the provided db match the guessed_db we should save it in the http session. Because all rpc call made before the authentication wont compute the guessed_db, so the request.db will be wrong for those calls. bzr revid: al@openerp.com-20131110010411-s7ermjwmfbile1ix --- addons/web/controllers/main.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/web/controllers/main.py b/addons/web/controllers/main.py index 58abda3fc30..81990f633ad 100644 --- a/addons/web/controllers/main.py +++ b/addons/web/controllers/main.py @@ -553,7 +553,7 @@ class Home(http.Controller): if db is None and guessed_db is not None: return redirect(guessed_db) - if db is not None and db != guessed_db: + if db is not None and db != request.session.db: request.session.logout() request.session.db = db guessed_db = db