mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-01 11:35:55 +01:00
logging unique IPs as well
This commit is contained in:
@@ -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();
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user