message: Sets status code for timeout errors
diff: @@ -18,6 +18,9 @@ ERROR_404.status = 404;
  const ERROR_401 = new Error('Access denied');
  ERROR_401.status = 401;
  +const ERROR_504 = new Error;
  +ERROR_504.status = 504;
  +
  export default (err, req, res, next) => {
  let error;
  @@ -32,5 +35,10 @@ export default (err, req, res, next) => {
  'unable to', // New-style errors
  ])) error = ERROR_401;
  + if (err.timeout) {
  + error = ERROR_504;
  + error.message = err.message;
  + }
  +
  return next(error || err);
  };
  