Open paletteOvO opened 1 month ago
Had this issue to after setting aot to false to make the bundled server work with headers. My workaround is to not use the mapResponse handler and instead, make a utility gzipping function that I call when return response in the controller/route.
What version of Elysia.JS is running?
Elysia 1.0.20
What platform is your computer?
Linux 6.8.9-273-tkg-eevdf-llvm x86_64 unknown
What steps can reproduce the bug?
What is the expected behavior?
What do you see instead?
No response
Additional information
Everything is fined when aot is false.
Also, I conducted some tests by removing the "onAfterHandle" and "mapResponse" handlers separately. I found that if there is an "onAfterHandle" handler present, the return of the "mapResponse" handler is ignored. However, everything works fine if both handlers are "onAfterHandle" or if there is only the gzipSync "mapResponse" handler.