From fbbc055a1eec1839095151eae024b67a7246ff5e Mon Sep 17 00:00:00 2001 From: Jan Malakhovski Date: Mon, 14 Oct 2024 13:00:00 +0000 Subject: [PATCH] extension: fix reqres without responses but with networking errors having "Responded at" field set in the logs --- extension/background/core.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/extension/background/core.js b/extension/background/core.js index 84b31c3..790c5b4 100644 --- a/extension/background/core.js +++ b/extension/background/core.js @@ -2514,6 +2514,7 @@ async function processOneAlmostDone(reqres, newProblematic, newLimbo, newQueued, // `onCompleted` does in this case, but it does not, so we have to // handle it specially here. reqres.responded = true; + reqres.responseTimeStamp = reqres.emitTimeStamp; reqres.statusCode = 200; reqres.reason = "Assumed OK"; // so that it would be marked as problematic, since actual metatada is not available @@ -3461,9 +3462,8 @@ function handleErrorOccurred(e) { // loading gets interrupted by another extension or a service/shared // worker. reqres.generated = true; - // NB: not setting reqres.responded - reqres.responseTimeStamp = e.timeStamp; reqres.fromCache = e.fromCache; + // NB: Not setting `reqres.responded`, nor `reqres.responseTimeStamp` here. // NB: This then continues to (raceCondition). }