Has anyone ever come accross the error `Trace: TypeError: Found invalid object in transferList` when

Has anyone ever come accross the error Trace: TypeError: Found invalid object in transferList when caching a response? The code I have is
if (response.status !== 404) {
        response.headers.set("cache-control", "max-age=3600")
        c.executionCtx.waitUntil(cache.put(req, response.clone()))
    }

and if I comment it out then I don't get the error. It only happens on this one endpoint
Was this page helpful?