Fix null options in checkPasswordComplexity()

This commit is contained in:
Yang Luo
2023-06-17 22:38:02 +08:00
parent ac4b870309
commit 12dee8afd3

View File

@ -57,7 +57,7 @@ export function checkPasswordComplexity(password, options) {
return i18next.t("login:Please input your password!"); return i18next.t("login:Please input your password!");
} }
if (options.length === 0) { if (!options || options.length === 0) {
options = ["AtLeast6"]; options = ["AtLeast6"];
} }