Update passwordStrength.ts

This commit is contained in:
Erkin Alp Güney 2022-04-09 21:48:25 +03:00 committed by GitHub
parent 6620265077
commit 07ed88ff6a

View File

@ -46,7 +46,7 @@ export function checkPassword(password: string): number {
strength = 0;
}
var entropyMap;
let entropyMap;
for (let i = 0; i < password.length; i++) {
if (entropyMap[password[i]]) entropyMap[password[i]]++;
else entropyMap[password[i]] = 1;