function reply(packet, json) {
  return _create(packet, packet.status || 500, (METHODS[packet.method] || '') + packet.resource, json);
}
function reply(packet, json) {
  return _create(packet, packet.status || 500, (METHODS[packet.method] || '') + packet.resource, json);
}
function reply ( packet , json ) { return _create ( packet , packet . status || 500 , ( METHODS [ packet . method ] || '' ) + packet . resource , json ) ; }
Serialize reply to array or JSON.

@param {Object}        packet
@param {String}        packet.method "get", "search", "post", "put", "delete", "sub", "unsub".
@param {String}        packet.resource
@param {String}        packet.id
@param {*}             packet.body
@param {Number}        [packet.status]
@param {Number|String} [packet.date]
@param {Object}        [packet.headers]
@param {Boolean}       [json] true to generate JSON instead of array.
@returns {Array|String|null}
Serialize reply to array or JSON .