New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
bug: alias connection to socket. #1590
Conversation
`ClientRequest.connection` is an alias for `ClientRequest.socket`. https://nodejs.org/api/http.html#http_request_socket https://github.com/nodejs/node/blob/master/lib/_http_client.js#L640-L641 `IncomingMessage.connection` is an alias for `IncomingMessage.socket`. https://github.com/nodejs/node/blob/master/lib/_http_incoming.js#L44-L45
Coveralls is complaining because the whole lib lost two executable lines, however, this change actually brings |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for picking this up!
d37cf74
to
9940410
Compare
Co-Authored-By: Paul Melnikow <github@paulmelnikow.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me, thanks Matt!
🎉 This PR is included in version 11.0.0-beta.20 🎉 The release is available on: Your semantic-release bot 📦🚀 |
🎉 This PR is included in version 11.0.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
`ClientRequest.connection` is an alias for `ClientRequest.socket`. https://nodejs.org/api/http.html#http_request_socket https://github.com/nodejs/node/blob/master/lib/_http_client.js#L640-L641 `IncomingMessage.connection` is an alias for `IncomingMessage.socket`. https://github.com/nodejs/node/blob/master/lib/_http_incoming.js#L44-L45 Co-Authored-By: Paul Melnikow <github@paulmelnikow.com>
`ClientRequest.connection` is an alias for `ClientRequest.socket`. https://nodejs.org/api/http.html#http_request_socket https://github.com/nodejs/node/blob/master/lib/_http_client.js#L640-L641 `IncomingMessage.connection` is an alias for `IncomingMessage.socket`. https://github.com/nodejs/node/blob/master/lib/_http_incoming.js#L44-L45 Co-Authored-By: Paul Melnikow <github@paulmelnikow.com>
`ClientRequest.connection` is an alias for `ClientRequest.socket`. https://nodejs.org/api/http.html#http_request_socket https://github.com/nodejs/node/blob/master/lib/_http_client.js#L640-L641 `IncomingMessage.connection` is an alias for `IncomingMessage.socket`. https://github.com/nodejs/node/blob/master/lib/_http_incoming.js#L44-L45 Co-Authored-By: Paul Melnikow <github@paulmelnikow.com>
ClientRequest.connection
is an alias forClientRequest.socket
.https://nodejs.org/api/http.html#http_request_socket
https://github.com/nodejs/node/blob/master/lib/_http_client.js#L640-L641
IncomingMessage.connection
is an alias forIncomingMessage.socket
.https://github.com/nodejs/node/blob/master/lib/_http_incoming.js#L44-L45
Adding
req.connection
andres.connection
as a basicEventEmitter
was to fix #74 when therequest
lib use to inspect the alias. This is not the case anymore.res.connection
was removed a few years later to improve coverage.