restify / node-restify

The future of Node.js REST development
http://restify.com
MIT License
10.71k stars 981 forks source link

feat: deprecate req.closed #1930

Closed mmarchini closed 1 year ago

mmarchini commented 1 year ago

Node.js added closed getter-only property to streams. This commit deprecates req.closed to avoid monkey-patching something that might be used in Node.js core or user-land libraries. req.connectionState() === 'close' can be used to achieve the same result moving forward. req.closed will be removed on Restify 10 to open way to support Node.js v18.

Pre-Submission Checklist

Issues

Closes:

Summarize the issues that discussed these changes

Changes

What does this PR do?