models: Update Realm.get_admin_users to not use select_related().

None of the uses of this function in the codebase follow any of the foreign
keys of UserProfile.
This commit is contained in:
Rishi Gupta 2017-12-19 14:19:52 -08:00 committed by showell
parent e9d7161418
commit c2a41c268f
1 changed files with 1 additions and 1 deletions

View File

@ -234,7 +234,7 @@ class Realm(models.Model):
def get_admin_users(self) -> Sequence['UserProfile']:
# TODO: Change return type to QuerySet[UserProfile]
return UserProfile.objects.filter(realm=self, is_realm_admin=True,
is_active=True).select_related()
is_active=True)
def get_active_users(self) -> Sequence['UserProfile']:
# TODO: Change return type to QuerySet[UserProfile]