aboutsummaryrefslogtreecommitdiffstats
path: root/src/account/views.py
diff options
context:
space:
mode:
Diffstat (limited to 'src/account/views.py')
-rw-r--r--src/account/views.py13
1 files changed, 6 insertions, 7 deletions
diff --git a/src/account/views.py b/src/account/views.py
index d0cfb22..f282369 100644
--- a/src/account/views.py
+++ b/src/account/views.py
@@ -61,16 +61,15 @@ class AccountSettingsView(UpdateView):
class MyOIDCAB(OIDCAuthenticationBackend):
def filter_users_by_claims(self, claims):
- email = claims.get(email=email)
+ email = claims.get('email')
if not email:
- return self.UserModel.objects.none()
+ return self.User.objects.none()
try:
- profile = Profile.objects.get(email=email)
- return profile.user
-
- except Profile.DoesNotExist:
- return self.UserModel.objects.none()
+ profile = UserProfile.objects.get('email')
+ return profile
+ except UserProfile.DoesNotExist:
+ return self.User.objects.none()
class JiraLoginView(RedirectView):