Fix another non integer argument to randomrange :^)

indiachan-spamvector
Thomas Lynch 2 years ago
parent 8f74885ba2
commit 6e80af2eec
  1. 2
      lib/captcha/generators/grid.js

@ -41,7 +41,7 @@ module.exports = async () => {
for(let j = 0; j < size; j++) { //for each row
//x offset for whole row (not per character or it gets way too difficult to solve)
let cxOffset = await randomRange(0, spaceSize * 1.5);
let cxOffset = await randomRange(0, Math.floor(spaceSize * 1.5));
for(let i = 0; i < size; i++) { //for character in row
const index = (j*size)+i;

Loading…
Cancel
Save