diff --git a/api/bot.py b/api/bot.py index 785a650..e3c5794 100644 --- a/api/bot.py +++ b/api/bot.py @@ -119,8 +119,8 @@ class Discord(discord.Client): info += "\n**This is only 10 applications out of {0} found. Please narrow your search if possible.**".format( len(applications)) else: - players = Player.objects.filter(username__icontains=search)[:10] - count = Player.objects.filter(username__icontains=search).count() + players = Player.objects.filter(username__icontains=search, application__isnull=False)[:10] + count = Player.objects.filter(username__icontains=search, application__isnull=False).count() if count > 0: if count == 1: yield from self.discord_message(message.channel, "No applications matched, however there is a player match.")