actual-server/util/error-middleware.js
2022-03-31 13:19:08 -04:00

6 lines
181 B
JavaScript

async function middleware(err, req, res, next) {
console.log('ERROR', err);
res.status(500).send({ status: 'error', reason: 'internal-error' });
}
module.exports = middleware;