Closed tahirmahmudzade closed 1 month ago
Hey there!
Good question, if you set throwError
to false, then instead of throwing the error by the middleware it will just return a json object with the error that you could catch and handle in your own desired way.
Would that solve it?
Unpess you are asking about adding custom errors for security headers or cors/csrf then these are not possible as we are using underlying packages/modules for that
Unpess you are asking about adding custom errors for security headers or cors/csrf then these are not possible as we are using underlying packages/modules for that
hey sorry i've been busy and completely missed your reply, and thanks a lot, you solved my problem. closing this issue.
I’m using the Nuxt Security module and would like to know if it’s possible to customize the error responses for different security configurations. For example, in the configuration below:
I noticed that I can use the throwError property for rate limiting, request size limiting, etc., to trigger errors when these limits are reached. Is there a way to customize the error message or response sent to the client when these security measures are enforced?