diff --git a/writeToStream.js b/writeToStream.js index 00ddcc6..86394fc 100644 --- a/writeToStream.js +++ b/writeToStream.js @@ -9,10 +9,10 @@ var protocol = require('./constants') if (process.version.indexOf('v0.1') === 0) { (function () { - nextTick = function tickShim (func, stream) { - return function () { + nextTick = function tickShim(func, stream) { + process.nextTick(function tickWrap() { return func(stream) - } + }) } })() }