diff options
| author | Adam Soltys <[email protected]> | 2026-01-26 09:29:18 -0800 |
|---|---|---|
| committer | Adam Soltys <[email protected]> | 2026-01-26 09:29:22 -0800 |
| commit | 360ead1d6787558a76fb16286b1a0a2dda44212e (patch) | |
| tree | 62de9f34614a4ca6e877457586f8dcd9e787b818 | |
| parent | 3420b3b7a1944d1ad483eefec13d75c04543b952 (diff) | |
| download | coinos-server-360ead1d6787558a76fb16286b1a0a2dda44212e.tar.gz coinos-server-360ead1d6787558a76fb16286b1a0a2dda44212e.zip | |
case insensitive usernames
| -rw-r--r-- | routes/users.ts | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/routes/users.ts b/routes/users.ts index c5fd0c39..60fe02f5 100644 --- a/routes/users.ts +++ b/routes/users.ts @@ -37,7 +37,10 @@ const verifyRecaptcha = async (response, req?) => { } const { username } = req.body; - if (await db.sIsMember("nocaptcha", username)) return true; + if ( + await db.sIsMember("nocaptcha", username.toLowerCase().replace(/\s/g, "")) + ) + return true; if (!response) return false; |
