Fix incorrect length of password and number gen
This commit is contained in:
parent
20327687ff
commit
1f756b1022
@ -1,3 +1,8 @@
|
||||
# Apple-Like Password Changelog
|
||||
|
||||
## [Bug Fix] - 2023-04-24
|
||||
|
||||
- Fix incorrect length of password
|
||||
- Fix number sometimes not generating
|
||||
|
||||
## [Initial Version] - 2023-04-24
|
@ -41,7 +41,7 @@ function generate() {
|
||||
// pick characters
|
||||
let count = 1;
|
||||
let passwordSection = "";
|
||||
for (let i = 1; i < 18; i++) {
|
||||
for (let i = 1; i <= 18; i++) {
|
||||
count += 1;
|
||||
|
||||
if (NumberPosition === i) {
|
||||
@ -68,7 +68,7 @@ function generate() {
|
||||
}
|
||||
|
||||
// separate characters into sections
|
||||
if (i % 6 === 0) {
|
||||
if (i !== 18 && i % 6 === 0) {
|
||||
passwordSection += "-";
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user