feat: bring back nopecha #599

This commit is contained in:
Elysia
2023-04-06 18:25:43 +07:00
parent 6d8efc6e00
commit 00d6a6a88a
4 changed files with 36 additions and 2 deletions

View File

@@ -1038,6 +1038,12 @@ class Client extends BaseClient {
throw new TypeError('CLIENT_INVALID_OPTION', 'captchaKey', 'a 32 character string');
}
break;
case 'nopecha': {
if (options.captchaKey.length !== 16) {
throw new TypeError('CLIENT_INVALID_OPTION', 'captchaKey', 'a 16 character string');
}
break;
}
}
}
if (typeof options.captchaRetryLimit !== 'number' || isNaN(options.captchaRetryLimit)) {