From 7b29cec0920821af57fcfd5d7047b2740ff198d5 Mon Sep 17 00:00:00 2001 From: Aevann Date: Thu, 14 Nov 2024 20:17:17 +0200 Subject: [PATCH] give error on namelock --- files/routes/awards.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/files/routes/awards.py b/files/routes/awards.py index def3e5253..5c61f564f 100644 --- a/files/routes/awards.py +++ b/files/routes/awards.py @@ -626,6 +626,9 @@ def award_thing(v, thing_type, id): author.flairchanged = int(time.time()) + 86400 * quantity badge_grant(user=author, badge_id=96) elif kind == "namelock": + if author.username.startswith('deleted~'): + stop(403, "Recipient account is deleted!") + new_name = note.strip().lstrip('@').strip() if author.namechanged and (not new_name or new_name == author.username): author.namechanged += 86400 * quantity