summaryrefslogtreecommitdiff
path: root/addons/website_google_map
diff options
context:
space:
mode:
authorJairo Llopis <yajo.sk8@gmail.com>2019-08-28 08:33:54 +0000
committerMartin Trigaux <mat@odoo.com>2019-09-12 06:18:18 +0000
commit5dad570423204c817f61d58b6d56bd376362e1b9 (patch)
tree5a44bae1f84859da928cdab12663780fc6b6bb64 /addons/website_google_map
parente7697ea472b29cfe6d595f530777914a6100de02 (diff)
[FIX] *: remove buggy calls to with_context
When .with_context() is called with a dictionary as 1st positional argument, it will replace context (and not modify the referenced keys) It may create bugs when losing the content of the context (e.g. remove partner's language) This is a partial merge of #36164 without the inventory part as discussed. closes odoo/odoo#36729 X-forward: 4717ccfa Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
Diffstat (limited to 'addons/website_google_map')
-rw-r--r--addons/website_google_map/controllers/main.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/addons/website_google_map/controllers/main.py b/addons/website_google_map/controllers/main.py
index 092fab26a03..afa7dd784f4 100644
--- a/addons/website_google_map/controllers/main.py
+++ b/addons/website_google_map/controllers/main.py
@@ -38,7 +38,7 @@ class GoogleMap(http.Controller):
"counter": len(partners),
"partners": []
}
- for partner in partners.with_context({'show_address': True}):
+ for partner in partners.with_context(show_address=True):
# TODO in master, do not use `escape` but `t-esc` in the qweb template.
partner_data["partners"].append({
'id': partner.id,