Moving Max Attempts to config

This commit is contained in:
ExtrasContainer
2024-02-04 09:42:04 +00:00
parent b73fff2d24
commit 477fda20a0
2 changed files with 3 additions and 2 deletions
+1
View File
@@ -14,6 +14,7 @@ module.exports = {
},
'captchaCount': '7',
'captchaTimeout': '120000', //in milliseconds (seconds multiplied by 1000)
'maxAttempts': '3', // max attemps to verify
'messages': {
//literally messages lmao
'toVerify': 'Please verify that you are not a robot.',
+1 -1
View File
@@ -54,7 +54,7 @@ module.exports = {
}
let attempts = 0;
const maxAttempts = 3;
const maxAttempts = cfg.maxAttempts;
let validated = false; // Flag to track if user is already validated
async function verifyUser(captcha) {