lib/index.js
function encodeBuffer(packet, supportsBinary, callback) {
  if (!supportsBinary) {
    return exports.encodeBase64Packet(packet, callback);
  }

  var data = packet.data;
  var typeBuffer = new Buffer(1);
  typeBuffer[0] = packets[packet.type];
  return callback(Buffer.concat([typeBuffer, data]));
}
function encodeBuffer(packet, supportsBinary, callback) {
  if (!supportsBinary) {
    return exports.encodeBase64Packet(packet, callback);
  }

  var data = packet.data;
  var typeBuffer = new Buffer(1);
  typeBuffer[0] = packets[packet.type];
  return callback(Buffer.concat([typeBuffer, data]));
}
function encodeBuffer ( packet , supportsBinary , callback ) { if ( ! supportsBinary ) { return exports . encodeBase64Packet ( packet , callback ) ; } var data = packet . data ; var typeBuffer = new Buffer ( 1 ) ; typeBuffer [ 0 ] = packets [ packet . type ] ; return callback ( Buffer . concat ( [ typeBuffer , data ] ) ) ; }
Encode Buffer data
Encode Buffer data