Skip to content

fix(playback): consistently check for destroyed attribute#2152

Merged
mastermatt merged 1 commit intonock:mainfrom
mastermatt:2146-req-destroyed
Feb 27, 2021
Merged

fix(playback): consistently check for destroyed attribute#2152
mastermatt merged 1 commit intonock:mainfrom
mastermatt:2146-req-destroyed

Conversation

@mastermatt
Copy link
Copy Markdown
Member

Node, as of 14.1, started migrating the Client Request terminology from
aborted to destroyed. In order to supported our current Node version
support, 10.x+, we need to check both flags. Nock was already doing this
in the router, but not during playback.

Identified from #2146

Node, as of 14.1, started migrating the Client Request terminology from
`aborted` to `destroyed`. In order to supported our current Node version
support, 10.x+, we need to check both flags. Nock was already doing this
in the router, but not during playback.
@mastermatt mastermatt requested a review from a team February 25, 2021 21:31
Comment thread lib/common.js
*
* @param {ClientRequest} req
* @returns {boolean}
*/
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

love all the context in the comment 👏

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same! Thank you, @mastermatt.

@mastermatt mastermatt merged commit b9758c8 into nock:main Feb 27, 2021
@mastermatt mastermatt deleted the 2146-req-destroyed branch February 27, 2021 03:22
@github-actions
Copy link
Copy Markdown

🎉 This PR is included in version 13.0.9 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants