logging unique IPs as well

This commit is contained in:
Julian Lam
2014-02-24 17:49:22 -05:00
parent aa71f1e088
commit c48d81379b
2 changed files with 4 additions and 3 deletions

View File

@@ -278,6 +278,9 @@ process.on('uncaughtException', function(err) {
// Disable framing
res.setHeader('X-Frame-Options', 'SAMEORIGIN');
// Log IP address
db.sortedSetAdd('ip:recent', +new Date(), req.ip || 'Unknown');
next();
});