Skip to content
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

Upgrade to node-fetch v2.x. #477

Merged
merged 2 commits into from
Jun 29, 2018
Merged

Upgrade to node-fetch v2.x. #477

merged 2 commits into from
Jun 29, 2018

Conversation

H1Gdev
Copy link
Collaborator

@H1Gdev H1Gdev commented Jun 24, 2018

Upgrade from node-fetch v1.x to node-fetch v2.x.
https://github.com/bitinn/node-fetch/blob/master/UPGRADE-GUIDE.md

@H1Gdev H1Gdev requested a review from vlucas June 24, 2018 01:15
@@ -31,7 +31,8 @@
"form-data": "^2.2.0",
"joi": "^13.0.0",
"lodash": "^4.17.10",
"node-fetch": "^1.5.2"
"node-fetch": "^2.1.2",
"encoding": "^0.1.12"
Copy link
Owner

Choose a reason for hiding this comment

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

Where is this module used?

@@ -128,7 +128,7 @@ class FrisbySpec {
this._fetch = fetch(this._request, { timeout: this.timeout() }) // 'timeout' is a node-fetch option
.then(response => {
this._response = new FrisbyResponse(response);
return response.text();
return response.textConverted();
Copy link
Owner

Choose a reason for hiding this comment

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

We can probably just use the text() method, right?

@H1Gdev
Copy link
Collaborator Author

H1Gdev commented Jun 26, 2018

@vlucas

encoding package and textConverted method are for Backward compatibility.(b42a82f)

https://github.com/bitinn/node-fetch/blob/master/UPGRADE-GUIDE.md#text-no-longer-tries-to-detect-encoding

@vlucas vlucas merged commit e40dd7b into vlucas:master Jun 29, 2018
@H1Gdev H1Gdev deleted the node-fetch branch June 30, 2018 23:52
@H1Gdev
Copy link
Collaborator Author

H1Gdev commented Jun 30, 2018

@vlucas

Thank you for your review.

PRs that I am planning is completed.

Please release new version.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants