|
|
@ -255,6 +255,14 @@ export class Response {
|
|
|
|
await this.sent$.next(this)
|
|
|
|
await this.sent$.next(this)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
|
|
|
* Returns true if the response can still be sent. False if it has been sent
|
|
|
|
|
|
|
|
* or the connection has been destroyed.
|
|
|
|
|
|
|
|
*/
|
|
|
|
|
|
|
|
public canSend(): boolean {
|
|
|
|
|
|
|
|
return !(this.responseEnded || this.serverResponse.destroyed)
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
/**
|
|
|
|
* Mark the response as ended and close the socket.
|
|
|
|
* Mark the response as ended and close the socket.
|
|
|
|
*/
|
|
|
|
*/
|
|
|
|