Always trim username updates

This commit is contained in:
Rory&
2025-12-02 16:36:29 +01:00
parent bd93ba0e99
commit 02f9f4f7ef

View File

@@ -140,7 +140,7 @@ router.patch(
}
if (body.username) {
const check_username = body?.username?.replace(/\s/g, "");
const check_username = body?.username?.replace(/\s/g, "").trim();
if (!check_username) {
throw FieldErrors({
username: {