add errors header with default value

This commit is contained in:
Simon Martín 2017-11-28 15:57:58 +01:00
parent a40c1e2331
commit 3e23be2087

View File

@ -100,6 +100,12 @@ function App(statsClient) {
app.use(global.log4js.connectLogger(global.log4js.getLogger(), _.defaults(loggerOpts, {level:'info'})));
}
// default X-SQLAPI-Errors header
app.use((req, res, next) => {
res.set('X-SQLAPI-Errors', '{}');
next();
});
app.use(cors());
// Use step-profiler