upd prod & morgan
This commit is contained in:
@ -27,7 +27,7 @@
|
||||
"password": "y0BZQ6of14OULYnb",
|
||||
"database": "saude_production",
|
||||
"synchronize": true,
|
||||
"logging": false
|
||||
"logging": true
|
||||
},
|
||||
"auth": {
|
||||
"refresh_token_lifetime_day": 30,
|
||||
|
||||
@ -4,12 +4,6 @@ import express from 'express';
|
||||
|
||||
export class MorganHelper {
|
||||
static setup(app: express.Application) {
|
||||
if (process.env.NODE_ENV == 'prod') {
|
||||
app.use(morgan(config.get('server.morgan'), {
|
||||
skip: function (req, res) { return res.statusCode < 400 }
|
||||
}));
|
||||
} else {
|
||||
app.use(morgan(config.get('server.morgan')));
|
||||
}
|
||||
app.use(morgan(config.get('server.morgan')));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user