Commit 2e033a7a authored by nachtgold's avatar nachtgold Committed by Hubert Denkmair
Browse files

final_mass was aliased

parent 8cd71e19
......@@ -20,7 +20,7 @@
{% for score in highscores %}
{% endfor %}
......@@ -3,5 +3,5 @@ from django.db.models import Max
from core.models import SnakeGame
def table(request):
data = SnakeGame.objects.values('user__username').annotate(score=Max('final_mass')).order_by('-final_mass')
data = SnakeGame.objects.values('user__username').annotate(score=Max('final_mass')).order_by('-score')
return render(request, 'highscore/table.html', context={'highscores': data})
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment