minor fix to namelock

master
Aevann 2023-10-22 22:18:17 +03:00
parent 01bb4da930
commit 6e67f4c295
1 changed files with 1 additions and 1 deletions

View File

@ -406,7 +406,7 @@ def award_thing(v, thing_type, id):
badge_grant(user=author, badge_id=96)
elif kind == "namelock":
new_name = note.strip().lstrip('@')
if not new_name and author.namechanged:
if (not new_name or new_name == author.username) and author.namechanged:
author.namechanged += 86400
else:
if not valid_username_regex.fullmatch(new_name):