DEP0136: http finished


类型: 仅文档

response.finished 表示 response.end() 是否已被调用,而不是 'finish' 是否已触发并刷新底层数据。

为保持现有行为,response.finished 应替换为 response.writableEnded

Type: Documentation-only

response.finished indicates whether response.end() has been called, not whether 'finish' has been emitted and the underlying data is flushed.

Use response.writableFinished or response.writableEnded accordingly instead to avoid the ambigiuty.

To maintain existing behaviour response.finished should be replaced with response.writableEnded.