mirror of
https://github.com/whoswhip/Sharpbin.git
synced 2026-12-06 02:48:43 +00:00
fix: lower vulnerabilities + harden docker setup
also includes a github workflow
This commit is contained in:
@@ -15,10 +15,14 @@ export const GET: RequestHandler = async ({ params, request }) => {
|
||||
statusText: 'Not Found'
|
||||
});
|
||||
}
|
||||
const content = await res.text();
|
||||
return new Response(content, {
|
||||
headers: {
|
||||
'Content-Type': 'text/plain; charset=utf-8'
|
||||
}
|
||||
const responseHeaders = new Headers(res.headers);
|
||||
responseHeaders.delete('content-encoding');
|
||||
responseHeaders.delete('content-length');
|
||||
responseHeaders.delete('transfer-encoding');
|
||||
|
||||
return new Response(await res.arrayBuffer(), {
|
||||
status: res.status,
|
||||
statusText: res.statusText,
|
||||
headers: responseHeaders
|
||||
});
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user