data.push(data.shift());
^
TypeError: Object TypeError: Cannot read property 'length' of undefined has no method 'shift'
at /home/joshux/Dropbox/node-stream-transform-play/node-stream-transform/samples/synchronous.js:8:18
at null. (/home/joshux/Dropbox/node-stream-transform-play/node-stream-transform/lib/index.js:70:14)
at EventEmitter.emit (events.js:95:17)
at Transformer._done (/home/joshux/Dropbox/node-stream-transform-play/node-stream-transform/lib/index.js:139:17)
at Transformer._transform (/home/joshux/Dropbox/node-stream-transform-play/node-stream-transform/lib/index.js:122:17)
at Transform._read (_stream_transform.js:179:10)
at Transform._write (_stream_transform.js:167:12)
at doWrite (_stream_writable.js:223:10)
at writeOrBuffer (_stream_writable.js:213:5)
at Writable.write (_stream_writable.js:180:11)
I ran: node samples/synchronous.js outputs:
data.push(data.shift()); ^ TypeError: Object TypeError: Cannot read property 'length' of undefined has no method 'shift' at /home/joshux/Dropbox/node-stream-transform-play/node-stream-transform/samples/synchronous.js:8:18 at null. (/home/joshux/Dropbox/node-stream-transform-play/node-stream-transform/lib/index.js:70:14)
at EventEmitter.emit (events.js:95:17)
at Transformer._done (/home/joshux/Dropbox/node-stream-transform-play/node-stream-transform/lib/index.js:139:17)
at Transformer._transform (/home/joshux/Dropbox/node-stream-transform-play/node-stream-transform/lib/index.js:122:17)
at Transform._read (_stream_transform.js:179:10)
at Transform._write (_stream_transform.js:167:12)
at doWrite (_stream_writable.js:223:10)
at writeOrBuffer (_stream_writable.js:213:5)
at Writable.write (_stream_writable.js:180:11)