fix request ip

This commit is contained in:
Philipinho
2026-05-07 22:09:32 +01:00
parent 2b63137217
commit ec51ca7815
+8
View File
@@ -50,6 +50,14 @@ async function bootstrap() {
await app.register(fastifyMultipart);
await app.register(fastifyCookie);
app
.getHttpAdapter()
.getInstance()
.addHook('onRequest', (request, _reply, done) => {
(request.raw as any).ip = request.ip;
done();
});
app
.getHttpAdapter()
.getInstance()