Merge pull request 'Sorting gamelist alphabetically' (#17) from sort-gamelist-alphabetically into master

Reviewed-on: #17
This commit is contained in:
odecif 2022-10-31 09:39:40 +01:00
commit 92a99ea0e1

View File

@ -24,6 +24,9 @@ def gamelist(lang_code):
glist = json.loads((requests.get( glist = json.loads((requests.get(
host_endpoint + '/gamelist').content).decode()) host_endpoint + '/gamelist').content).decode())
# Sorting list alphabetically
glist = sorted(glist, key=lambda d: d['game']['title'])
return render_template('gamelist.html', gamelist=glist, return render_template('gamelist.html', gamelist=glist,
**languages[lang_code], lang_code=lang_code) **languages[lang_code], lang_code=lang_code)