Skip to content


Subversion checkout URL

You can clone with
Download ZIP
Browse files

updated for concat-stream 1.0.0

  • Loading branch information...
commit cfacf6c40b216d28df95eaca8755f0b8c7a697a3 1 parent 3e7df18
@substack authored
Showing with 4 additions and 4 deletions.
  1. +4 −4 readme.markdown
8 readme.markdown
@@ -451,8 +451,8 @@ until the `'connect'` event fires.
## [concat-stream](
concat-stream will buffer up stream contents into a single buffer.
-`concat(cb)` just takes a single callback `cb(err, body)` with the buffered
-`body` when the stream has ended and an `err` if there was an error.
+`concat(cb)` just takes a single callback `cb(body)` with the buffered
+`body` when the stream has finished.
For example, in this program, the concat callback fires with the body string
`"beep boop"` once `cs.end()` is called.
@@ -461,7 +461,7 @@ The program takes the body and upper-cases it, printing `BEEP BOOP.`
``` js
var concat = require('concat-stream');
-var cs = concat(function (err, body) {
+var cs = concat(function (body) {
cs.write('beep ');
@@ -483,7 +483,7 @@ var qs = require('querystring');
var concat = require('concat-stream');
var server = http.createServer(function (req, res) {
- req.pipe(concat(function (err, body) {
+ req.pipe(concat(function (body) {
var params = qs.parse(body);
res.end(JSON.stringify(params) + '\n');
Please sign in to comment.
Something went wrong with that request. Please try again.