Skip to content

Commit

Permalink
Do not return the nock global from cleanAll() (#1872)
Browse files Browse the repository at this point in the history
BREAKING CHANGE: Do not return the `nock` global from `cleanAll()` (#1872)
  • Loading branch information
paulmelnikow authored and gr2m committed Feb 16, 2020
1 parent e33b3e8 commit 0a4a944
Showing 1 changed file with 1 addition and 8 deletions.
9 changes: 1 addition & 8 deletions index.js
Expand Up @@ -29,14 +29,7 @@ Object.assign(module.exports, {
removeInterceptor,
disableNetConnect,
enableNetConnect,
// TODO-12.x Historically `nock.cleanAll()` has returned the nock global.
// The other global methods do not do this, so it's not clear this was
// deliberate or is even helpful. This shim is included for backward
// compatibility and should be replaced with an alias to `removeAll()`.
cleanAll() {
removeAll()
return module.exports
},
cleanAll: removeAll,
abortPendingRequests,
load,
loadDefs,
Expand Down

0 comments on commit 0a4a944

Please sign in to comment.