docs: correct the information regarding generic request port variable

This commit is contained in:
Dorian Niemiec 2025-01-11 17:41:46 +01:00
parent cc20ed04f5
commit 234429a120

View file

@ -131,7 +131,7 @@ You can specify generic request IP variable using `const reqip = req.socket.real
A property containing port number, from which request originally went from, if request is sent through reverse proxy. (for _X-Forwarded-For_ header, it will be _null_) A property containing port number, from which request originally went from, if request is sent through reverse proxy. (for _X-Forwarded-For_ header, it will be _null_)
You can specify generic request IP variable using `const reqip = req.socket.realRemotePort ? req.socket.realRemotePort : req.socket.remotePort` You can specify generic request port variable using `const reqport = req.socket.realRemotePort ? req.socket.realRemotePort : req.socket.remotePort`
### _req.socket.originalRemoteAddress_ ### _req.socket.originalRemoteAddress_
@ -206,7 +206,7 @@ You can specify generic request IP variable using `const reqip = req.socket.real
A property containing port number, from which request originally went from, if request is sent through reverse proxy. (for _X-Forwarded-For_ header, it will be _null_) A property containing port number, from which request originally went from, if request is sent through reverse proxy. (for _X-Forwarded-For_ header, it will be _null_)
You can specify generic request IP variable using `const reqip = req.socket.realRemotePort ? req.socket.realRemotePort : req.socket.remotePort` You can specify generic request port variable using `const reqport = req.socket.realRemotePort ? req.socket.realRemotePort : req.socket.remotePort`
### _res.socket.originalRemoteAddress_ ### _res.socket.originalRemoteAddress_