site_opytex/theme/node_modules/vinyl/lib/inspectStream.js

12 lines
264 B
JavaScript
Raw Permalink Normal View History

var isStream = require('./isStream');
module.exports = function(stream) {
if (!isStream(stream)) return;
var streamType = stream.constructor.name;
// avoid StreamStream
if (streamType === 'Stream') streamType = '';
return '<'+streamType+'Stream>';
};