fix : 12 to 6 for password

This commit is contained in:
2026-10-02 12:15:37 +07:00 Unverified
parent 96c27f8fc3
commit 724234a6f9
4 changed files with 5 additions and 5 deletions
+1 -1
View File
@@ -16,7 +16,7 @@ async function mutate(request: Request) {
const password = input && typeof input === "object" && "password" in input ? input.password : undefined;
const newPassword = input && typeof input === "object" && "newPassword" in input ? input.newPassword : undefined;
const value = password ?? newPassword;
if (typeof value !== "string" || value.length < 12 || value.length > 128) {
if (typeof value !== "string" || value.length < 6 || value.length > 128) {
throw new HttpError(400, "invalid-password-length");
}
}