DONE ONCE AGAIN
This commit is contained in:
@@ -13,7 +13,7 @@ import { setResp403 } from '../helpers/http.js'
|
||||
* @param res
|
||||
* @returns {Promise<void>}
|
||||
*/
|
||||
export const setForbidden = async (req, res) => {
|
||||
const setForbidden = async (req, res) => {
|
||||
const ip = req.headers['x-forwarded-for'] || req.connection.remoteAddress
|
||||
res.status(403).json(setResp403(`You are not allowed to access the resource. Your IP is ${ip}`))
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user