+ if (typeof res.body === 'string') {
+ data.body = logTruncate(data.body, 100);
+ } else if (res.body instanceof Buffer) {
+ data.body = `<Buffer ${res.body.byteLength} bytes>`;
+ }
+ if (res?.timings?.phases?.total) {
+ data.elapsedTimeMs = res.timings.phases.total;
+ }
+ if (res?.redirectUrls?.length) {
+ data.redirectUrls = res.redirectUrls;
+ }
+ if (res?.retryCount) {
+ data.retryCount = res.retryCount;