[fix] git

This commit is contained in:
kwaroran
2023-09-09 09:07:27 +09:00
parent 44accff661
commit 16d567ed9f

View File

@@ -69,19 +69,18 @@ const proxyFunc = async (req, res, next) => {
const originalBody = await originalResponse.text(); const originalBody = await originalResponse.text();
const head = new Headers(originalResponse.headers); const head = new Headers(originalResponse.headers);
head.delete('content-security-policy');
head.delete('content-security-policy-report-only');
head.delete('clear-site-data');
head.delete('Cache-Control');
const headObj = {}; const headObj = {};
for (let [k, v] of head) { for (let [k, v] of head) {
headObj[k] = v; headObj[k] = v;
} }
res.header(headObj); res.header(headObj);
head.delete('content-security-policy');
head.delete('content-security-policy-report-only');
head.delete('clear-site-data');
head.delete('Cache-Control');
if(status < 200 || status >= 300){ if(status < 200 || status >= 300){
res.status(status) res.status(status)
} }
res.header(head)
res.send(originalBody); res.send(originalBody);
} }