@webdecoy/express 0.28.0 → 0.30.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.
- package/dist/index.js +4 -1
- package/dist/index.mjs +4 -1
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -177,7 +177,10 @@ function webdecoyCaptcha(options) {
|
|
|
177
177
|
return;
|
|
178
178
|
}
|
|
179
179
|
res.status(result.status);
|
|
180
|
-
for (const [
|
|
180
|
+
for (const [name, value] of Object.entries(result.headers)) {
|
|
181
|
+
if (name === "set-cookie") res.append(name, value);
|
|
182
|
+
else res.setHeader(name, value);
|
|
183
|
+
}
|
|
181
184
|
res.json(result.body);
|
|
182
185
|
}
|
|
183
186
|
}
|
package/dist/index.mjs
CHANGED
|
@@ -162,7 +162,10 @@ function webdecoyCaptcha(options) {
|
|
|
162
162
|
return;
|
|
163
163
|
}
|
|
164
164
|
res.status(result.status);
|
|
165
|
-
for (const [
|
|
165
|
+
for (const [name, value] of Object.entries(result.headers)) {
|
|
166
|
+
if (name === "set-cookie") res.append(name, value);
|
|
167
|
+
else res.setHeader(name, value);
|
|
168
|
+
}
|
|
166
169
|
res.json(result.body);
|
|
167
170
|
}
|
|
168
171
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@webdecoy/express",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.30.0",
|
|
4
4
|
"description": "Web Decoy middleware for Express.js",
|
|
5
5
|
"main": "./dist/index.js",
|
|
6
6
|
"types": "./dist/index.d.ts",
|
|
@@ -40,7 +40,7 @@
|
|
|
40
40
|
"url": "https://github.com/WebDecoy/node/issues"
|
|
41
41
|
},
|
|
42
42
|
"dependencies": {
|
|
43
|
-
"@webdecoy/node": "^0.
|
|
43
|
+
"@webdecoy/node": "^0.30.0"
|
|
44
44
|
},
|
|
45
45
|
"peerDependencies": {
|
|
46
46
|
"express": "^4.18.0 || ^5.0.0"
|