We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 01c99d6 commit db441c1Copy full SHA for db441c1
index.js
@@ -40,6 +40,7 @@ async function service (req, res) {
40
<ul>
41
<li>?href=<href> - <i>required</i>, the URL you are trying to reach</li>
42
<li>&method=<method> - <i>optional</i>, the HTTP method to use</li>
43
+ <li>&<HTTP Header>=<value> - <i>optional</i>, set any supported HTTP headers</li>
44
</ul>
45
<h2>Supported Headers</h2>
46
@@ -52,7 +53,7 @@ async function service (req, res) {
52
53
let headers = {}
54
for (let h of allowHeaders) {
55
if (req.headers[h]) {
- headers[h] = req.headers[h]
56
+ headers[h] = q[h] || req.headers[h]
57
}
58
59
let f = await fetch(q.href, {
0 commit comments