diff --git a/corehq/apps/users/models.py b/corehq/apps/users/models.py index 4ba6d39b5e90..7be1a1291170 100644 --- a/corehq/apps/users/models.py +++ b/corehq/apps/users/models.py @@ -1170,7 +1170,7 @@ def get_django_user(self, use_primary_db=False): queryset = User.objects if use_primary_db: queryset = queryset.using(router.db_for_write(User)) - return queryset.get(username__iexact=self.username) + return queryset.get(username=self.username) def add_phone_number(self, phone_number, default=False, **kwargs): """ Don't add phone numbers if they already exist """