added basic logger using config.json

v1.18.x
Andrew Darqui 11 years ago
parent 1c32acf7b6
commit 51d7dda5a7

@ -79,6 +79,9 @@ var express = require('express'),
function(next) { function(next) {
// Pre-router middlewares // Pre-router middlewares
app.use(express.compress()); app.use(express.compress());
if(nconf.get("express:logger") == true) {
app.use(express.logger());
}
app.use(express.favicon(path.join(__dirname, '../', 'public', 'favicon.ico'))); app.use(express.favicon(path.join(__dirname, '../', 'public', 'favicon.ico')));
app.use(require('less-middleware')({ app.use(require('less-middleware')({
src: path.join(__dirname, '../', 'public'), src: path.join(__dirname, '../', 'public'),
@ -544,4 +547,4 @@ var express = require('express'),
}(WebServer)); }(WebServer));
global.server = server; global.server = server;

Loading…
Cancel
Save