summaryrefslogtreecommitdiff
path: root/addons/auth_oauth/controllers
diff options
context:
space:
mode:
authorDenis Ledoux <dle@odoo.com>2014-06-17 09:26:20 +0200
committerDenis Ledoux <dle@odoo.com>2014-06-17 09:26:20 +0200
commitb58703857012d42f9a39363611894014c2166a8e (patch)
tree6a079a6d9b4c8c731b3deff064b7181771068e95 /addons/auth_oauth/controllers
parenta3cfe1728d048ee23d8c7a41c0f1df8a70f0aeec (diff)
[FIX] auth_oauth: url_unquote_plus does not handle boolean
If the redirect param 'r' is not in the state, do no try to unquote it
Diffstat (limited to 'addons/auth_oauth/controllers')
-rw-r--r--addons/auth_oauth/controllers/main.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/addons/auth_oauth/controllers/main.py b/addons/auth_oauth/controllers/main.py
index 6743cf17e7b..214fdefe1fb 100644
--- a/addons/auth_oauth/controllers/main.py
+++ b/addons/auth_oauth/controllers/main.py
@@ -116,7 +116,7 @@ class OAuthController(http.Controller):
cr.commit()
action = state.get('a')
menu = state.get('m')
- redirect = werkzeug.url_unquote_plus(state.get('r'))
+ redirect = werkzeug.url_unquote_plus(state['r']) if state.get('r') else False
url = '/web'
if redirect and not redirect.startswith('/auth_oauth/signin') and \
(not redirect.startswith('/web/login') or 'redirect' in urlparse.urlsplit(redirect).query):