Skip to content

Commit

Permalink
feat: using req.ip instead of req.socket.remoteAddress
Browse files Browse the repository at this point in the history
  • Loading branch information
artursudnik committed Oct 17, 2023
1 parent ae1e3b3 commit ada39fc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion apps/vc-api/src/middlewares/http-logger.middleware.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ export class HttpLoggerMiddleware implements NestMiddleware {
let finished = false;

res.on('finish', () => {
const message = `${res.statusCode} ${res.statusMessage} | [${method}] ${url} - ${
const message = `${res.statusCode} ${res.statusMessage} | ${req.ip} | [${method}] ${url} - ${
Date.now() - requestStarted
}ms`;

Expand Down

0 comments on commit ada39fc

Please sign in to comment.