Update server_commands.py

This commit is contained in:
Elmon11 2020-12-18 18:03:49 +01:00 committed by GitHub
parent c45f68999e
commit 73b08a360d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -238,7 +238,7 @@ class ServerCommands(commands.Cog):
entries.append(format_list_entry(em, json[rank], f'{" ".join(rank_fixed)}')) entries.append(format_list_entry(em, json[rank], f'{" ".join(rank_fixed)}'))
order = ['Owners', 'Executives', 'Developers', 'Senior Admins', 'Admins', 'Master Builders', 'Operators', 'Imposters'] order = ['Owners', 'Executives', 'Developers', 'Senior Admins', 'Admins', 'Master Builders', 'Operators', 'Imposters']
sorted = [tpl for x in order for tpl in entries if tpl.name == x] sorted = [entry for rank in order for entry in entries if entry.name == rank]
for x in sorted: for x in sorted:
em.add_field(name=f'{x.name} ({x.playercount})', value=x.value, inline=False) em.add_field(name=f'{x.name} ({x.playercount})', value=x.value, inline=False)