def total_badges_earned(self):
        """Returns the total number of badges earned by the user.
           Doesn't include hidden unlocked badges from an upper level.
        """
        return CompletedChallenge.objects.filter(profile=self, date_badge_earned__isnull=False).count()