1
0
mirror of https://github.com/gorhill/uBlock.git synced 2024-07-05 11:37:01 +02:00

Generate new Response when no match in trusted-replace-fetch-response scriptlet

Somehow, sending the original Response instance causes issues.
This commit is contained in:
Raymond Hill 2023-08-07 13:06:54 -04:00
parent 5ee00a6b68
commit 1762ea3950
No known key found for this signature in database
GPG Key ID: 25E1490B761470C2

View File

@ -3424,7 +3424,6 @@ function trustedReplaceFetchResponse(
`\n\treplacement: ${replacement}`,
);
}
if ( textAfter === textBefore ) { return responseBefore; }
const responseAfter = new Response(textAfter, {
status: responseBefore.status,
statusText: responseBefore.statusText,