code: function xreqhan(res, req, output) {
      if (isResHeaderSent(res)) {
          return console.error('request already closed', new Error().stack);
      }
      output = output || '';
      var isBinary = output && Buffer.isBuffer(output);
      if (isBinary) {
          res.end(output, 'binary');
      }
      else if (res.send) { //Express adds send
          res.send(output);
      }
      else if (res.end) { //base way to end request
          output = reqResOutputToString(req, res, output);
          res.end(output);
      }
      resMarkClosed(res); //add indicators that show response has been closed
  }
docs: close request handler