mirror of
https://github.com/MercuryWorkshop/scramjet.git
synced 2025-05-15 07:20:02 -04:00
add lint command, lint and lint:fix project
This commit is contained in:
parent
430c7ad6ec
commit
93b609932d
23 changed files with 36916 additions and 25 deletions
|
@ -79,7 +79,7 @@ export async function swfetch(
|
|||
new URL(client.url).pathname.startsWith(self.$scramjet.config.prefix)
|
||||
) {
|
||||
// TODO: i was against cors emulation but we might actually break stuff if we send full origin/referrer always
|
||||
let url = new URL(decodeUrl(client.url));
|
||||
const url = new URL(decodeUrl(client.url));
|
||||
headers.set("Referer", url.toString());
|
||||
headers.set("Origin", url.origin);
|
||||
}
|
||||
|
@ -135,7 +135,7 @@ async function handleResponse(
|
|||
let responseBody: string | ArrayBuffer | ReadableStream;
|
||||
const responseHeaders = rewriteHeaders(response.rawHeaders, newmeta(url));
|
||||
|
||||
let maybeHeaders = responseHeaders["set-cookie"] || [];
|
||||
const maybeHeaders = responseHeaders["set-cookie"] || [];
|
||||
for (const cookie in maybeHeaders) {
|
||||
if (client)
|
||||
client.postMessage({
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue