Skip to content

Commit

Permalink
fix: lower the user names when sorting
Browse files Browse the repository at this point in the history
  • Loading branch information
zhuhanming committed May 5, 2021
1 parent 288d35b commit af6e1c6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/chat_handlers.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ def generate_user_list(chat: dict, users: list[dict]) -> str:
return "There are no members in this chat!\nPlease add yourself with the /add_me command."

message = "<b>Members in {}:</b>\n".format(chat["title"])
users.sort(key=lambda x: str(x["full_name"]))
users.sort(key=lambda x: str(x["full_name"]).lower())
for user in users:
message += "{}\n".format(user["full_name"])

Expand Down

0 comments on commit af6e1c6

Please sign in to comment.