mirror of
https://github.com/spacebarchat/server.git
synced 2026-10-22 19:43:16 +00:00
eslint: yoda
This commit is contained in:
1 parent
a8204b0c02
commit
c5504878b8
4 files changed
+7
-5
No files matched your search
@@ -44,12 +44,12 @@ export function checkPassword(password: string): number {
|
||||
}
|
||||
|
||||
// checks for amount of Numbers
|
||||
if (password.match(reNUMBER)?.length ?? 0 >= minNumbers - 1) {
|
||||
if ((password.match(reNUMBER)?.length ?? 0) >= minNumbers - 1) {
|
||||
strength += 0.05;
|
||||
}
|
||||
|
||||
// checks for amount of Uppercase Letters
|
||||
if (password.match(reUPPERCASELETTER)?.length ?? 0 >= minUpperCase - 1) {
|
||||
if ((password.match(reUPPERCASELETTER)?.length ?? 0) >= minUpperCase - 1) {
|
||||
strength += 0.05;
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user