Skip to content

Commit

Permalink
Remove totpdevice annotation
Browse files Browse the repository at this point in the history
No longer used after migrating to built in 2FA.
  • Loading branch information
jmsmkn authored May 3, 2024
1 parent 0233c26 commit f5a4c24
Showing 1 changed file with 0 additions and 11 deletions.
11 changes: 0 additions & 11 deletions app/grandchallenge/profiles/admin.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,17 +52,6 @@ class UserProfileAdmin(UserAdmin):
)
actions = (deactivate_users,)

def get_queryset(self, request):
return (
super()
.get_queryset(request)
.annotate(
totp_device_count=Count(
"totpdevice", filter=Q(totpdevice__confirmed=True)
)
)
)

@admin.display(boolean=True, description="User has 2FA enabled")
def has_2fa_enabled(self, obj):
return is_mfa_enabled(obj)
Expand Down

0 comments on commit f5a4c24

Please sign in to comment.