Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions hvzsite/hvz/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -426,15 +426,16 @@ class ApiPlayers(APIView):
Returns all player information
'''
def get(self, request):
game = get_active_game()
players = [
{
'name': p.readable_name(request.user.is_authenticated and request.user.active_this_game),
'id': p.player_uuid,
'status': p.current_status.get_status_display(),
'tags': p.current_status.num_tags,
} for p in Person.objects.all()
} for p in Person.full_name_objects.filter(playerstatus__game=game, playerstatus__status__in=['h','v','e','z','o','x','a','m'])
]

data = {
'players': players
}
Expand Down