@webdecoy/fcaptcha 1.44.0 → 1.45.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/server.js +4 -1
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@webdecoy/fcaptcha",
3
- "version": "1.44.0",
3
+ "version": "1.45.0",
4
4
  "description": "Open source CAPTCHA with PoW, bot detection, and Vision AI protection",
5
5
  "main": "index.js",
6
6
  "exports": {
package/server.js CHANGED
@@ -165,7 +165,10 @@ const CLIENT_PATH = process.env.FCAPTCHA_CLIENT_PATH
165
165
  || path.join(__dirname, '..', 'client', 'fcaptcha.js');
166
166
 
167
167
  if (process.env.FCAPTCHA_SERVE_CLIENT !== 'false') {
168
- app.get('/fcaptcha.js', (req, res) => {
168
+ // The same file on each provider's script path, where it answers to that
169
+ // provider's global, so apps that let an admin change a Turnstile, hCaptcha
170
+ // or reCAPTCHA URL can point it here (see installCompat in the client).
171
+ app.get(['/fcaptcha.js', '/turnstile/v0/api.js', '/1/api.js', '/recaptcha/api.js'], (req, res) => {
169
172
  res.sendFile(CLIENT_PATH);
170
173
  });
171
174
  }