Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions src/telemetry/requestLogger.ts
Original file line number Diff line number Diff line change
Expand Up @@ -80,10 +80,11 @@ function finishLog<SLocals extends AnyServiceLocals = ServiceLocals<Configuratio
}
const [url, preInfo] = getBasicInfo(req);

let responseType = 'finished';
let responseType = 'unknown';

// ts warning is known and incorrect—`aborted` is a subset of `destroyed`
if (req.aborted) {
if (res.writableFinished) {
responseType = 'finished';
} else if (req.aborted) {
responseType = 'aborted';
} else if (req.destroyed) {
responseType = 'destroyed';
Expand Down
Loading