This commit is contained in:
Daniel Odendahl Jr
2018-01-26 14:40:40 +00:00
parent 6e96c5e914
commit 6953ef2811
+1 -1
View File
@@ -43,7 +43,7 @@ module.exports = class CaptchaQuizCommand extends Command {
randomText(len) {
const pool = 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ23456789'.split('');
const result = [];
for (let i = 0; i > len; i++) result.push(pool[Math.floor(Math.random() * pool.length)]);
for (let i = 0; i < len; i++) result.push(pool[Math.floor(Math.random() * pool.length)]);
return result.join('');
}
};