Skip to content

Commit

Permalink
refactor: add family args (PR #204)
Browse files Browse the repository at this point in the history
  • Loading branch information
aacerox committed Oct 10, 2023
1 parent 427b4a4 commit 54db223
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .changeset/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"fixed": [],
"linked": [],
"access": "restricted",
"baseBranch": "master",
"baseBranch": "feat/general-upgrade",
"updateInternalDependencies": "patch",
"ignore": []
}
5 changes: 5 additions & 0 deletions .changeset/fuzzy-dancers-unite.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'node-rest-client': minor
---

add family args (PR #204 Update: add family args)
5 changes: 5 additions & 0 deletions lib/NrcIoManager.js
Original file line number Diff line number Diff line change
Expand Up @@ -540,6 +540,11 @@ export default class NrcIoManager extends events.EventEmitter {
} else {
options.headers[CONSTANTS.HEADER_CONTENT_LENGTH] = 0;
}

// add family arg for fix DNS error, https://github.com/nodejs/node/issues/5436
if (args.family === 4 || args.family === 6) {
options.family = args.family;
}
}

debug('options post connect', options);
Expand Down

0 comments on commit 54db223

Please sign in to comment.