I am trying to create global error handling middleware which will catch defect in my app, wrap it with proper data and return to the client.
I tried something like this and i got proper output in my request logger but there is no response sent to the client. What am i doing wrong?