projects
/
odoo
/
odoo.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
451b6b9
)
[FIX] auth_oauth: hide invalid providers from login screen
author
Richard Mathot
<rim@openerp.com>
Wed, 2 Jul 2014 12:07:52 +0000
(14:07 +0200)
committer
Richard Mathot
<rim@openerp.com>
Wed, 2 Jul 2014 12:07:52 +0000
(14:07 +0200)
addons/auth_oauth/controllers/main.py
patch
|
blob
|
history
diff --git
a/addons/auth_oauth/controllers/main.py
b/addons/auth_oauth/controllers/main.py
index
62eb2e8
..
8fb7ce9
100644
(file)
--- a/
addons/auth_oauth/controllers/main.py
+++ b/
addons/auth_oauth/controllers/main.py
@@
-46,7
+46,7
@@
class OAuthController(oeweb.Controller):
registry = RegistryManager.get(dbname)
with registry.cursor() as cr:
providers = registry.get('auth.oauth.provider')
- l = providers.read(cr, SUPERUSER_ID, providers.search(cr, SUPERUSER_ID, [('enabled', '=', True)]))
+ l = providers.read(cr, SUPERUSER_ID, providers.search(cr, SUPERUSER_ID, [('enabled', '=', True), ('auth_endpoint', '!=', False), ('validation_endpoint', '!=', False)]))
except Exception:
l = []
return l