Skip to content

Commit

Permalink
Generate bulk not equal comparison for better readability
Browse files Browse the repository at this point in the history
  • Loading branch information
llouka committed Jan 25, 2023
1 parent e1c4a4c commit 13d3736
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/totp/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ export const generateBulk = (
clockStart = 0,
} = options
const result: BulkCode[] = []
for (let index = 0; index <= amount; index++) {
for (let index = 0; index < amount; index++) {
const timeSlot = Math.floor((receiveTime - clockStart) / timeStep) + index
result.push({
code: HOTP.generate(secret, timeSlot, options),
Expand Down

0 comments on commit 13d3736

Please sign in to comment.