Normalise usernames when searching

This commit is contained in:
Evan Smith 2022-11-05 17:07:32 +00:00 committed by Ivan Habunek
parent 1387d045eb
commit 8b274eeaa1
1 changed files with 2 additions and 1 deletions

View File

@ -251,7 +251,8 @@ def _find_account(app, user, account_name):
account_name = account_name[1:]
for account in accounts:
if account['acct'] == account_name:
# Normalise string matching because usernames are case insensitive
if account['acct'].lower() == account_name.lower():
return account
raise ConsoleError("Account not found")