Allow to configure "none" captcha resolver

This commit is contained in:
ngosang
2021-01-10 15:04:18 +01:00
parent 91d1f0cb4a
commit a57510aa0d
2 changed files with 4 additions and 2 deletions

View File

@@ -18,7 +18,9 @@ const captchaSolvers: { [key: string]: Solver } = {}
export default (): Solver => {
const method = process.env.CAPTCHA_SOLVER
if (!method) { return null }
if (!method || method.toLowerCase() == 'none') {
return null;
}
if (!(method in captchaSolvers)) {
try {