diff --git a/index.js b/index.js index 38a5e79..8323e65 100644 --- a/index.js +++ b/index.js @@ -3,12 +3,9 @@ var eos = require('end-of-stream') var inherits = require('inherits') var shift = require('stream-shift') -var SIGNAL_FLUSH -if (Buffer.from && Buffer.from !== Uint8Array.from) { - SIGNAL_FLUSH = Buffer.from([0]) -} else { - SIGNAL_FLUSH = new Buffer([0]) -} +var SIGNAL_FLUSH = (Buffer.from && Buffer.from !== Uint8Array.from) + ? Buffer.from([0]) + : new Buffer([0]) var onuncork = function(self, fn) { if (self._corked) self.once('uncork', fn)