diff options
| author | Olivier Dony <odo@openerp.com> | 2014-07-05 01:28:19 +0200 |
|---|---|---|
| committer | Olivier Dony <odo@openerp.com> | 2014-07-05 01:28:19 +0200 |
| commit | d9cda97cf47f78bff309aff2e6adff5808f9734d (patch) | |
| tree | 3bbba24b15b7d0901d5bf82fed3b1dc07f72c6b3 /addons/auth_oauth/controllers/main.py | |
| parent | f0ef8ac446115c0cb40a07a3792095c76d45c8e2 (diff) | |
| parent | 5ceded9d69b3c261e501500e760b9b345bb77ecc (diff) | |
[MERGE] Forward-port saas-4 up to 5ceded9
Diffstat (limited to 'addons/auth_oauth/controllers/main.py')
| -rw-r--r-- | addons/auth_oauth/controllers/main.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/addons/auth_oauth/controllers/main.py b/addons/auth_oauth/controllers/main.py index 7652420d7c6..1a166c39cde 100644 --- a/addons/auth_oauth/controllers/main.py +++ b/addons/auth_oauth/controllers/main.py @@ -49,7 +49,8 @@ class OAuthLogin(Home): def list_providers(self): try: provider_obj = request.registry.get('auth.oauth.provider') - providers = provider_obj.search_read(request.cr, SUPERUSER_ID, [('enabled', '=', True)]) + providers = provider_obj.search_read(request.cr, SUPERUSER_ID, [('enabled', '=', True), ('auth_endpoint', '!=', False), ('validation_endpoint', '!=', False)]) + # TODO in forwardport: remove conditions on 'auth_endpoint' and 'validation_endpoint' when these fields will be 'required' in model except Exception: providers = [] for provider in providers: |
