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

Challenge 8 HTTP Collect example doesn't support error-first callback for concat-stream #462

Open
kwhms opened this issue Aug 26, 2016 · 1 comment

Comments

@kwhms
Copy link

kwhms commented Aug 26, 2016

The example in the instructions uses response.pipe(concatStream(function (data) { /* ... */ })). Trying to modify this for error handling as a best practice as response.pipe(concatStream(function (err, data) { /* ... */ })) fails.

This can be simply fixed by changing the instructions/example to use concat-stream-callback instead of concat-stream. Thus,

var concatStreamCallback = require('concat-stream-callback');

response.pipe(concatStreamCallback(function (err, data) {/* ... */}))
@AnshulMalik
Copy link
Contributor

We'd definitely want to modify the exercise, PR welcome :)

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

No branches or pull requests

2 participants