code: function(readStream, next) {
      var hash = crypto.createHash('sha1');
      hash.setEncoding('hex');
  
      readStream.on('end', function() {
          hash.end();
          next(false, hash.read());
      });
  
      readStream.on('error', function(err) {
        next(err);
      });
  
      readStream.pipe(hash);
    }
docs: Stream helpers