Skip to content

Returning monads/Result types in controllers #4843

Answered by Julien-R44
tbarusseau asked this question in Help
Discussion options

You must be logged in to vote

I think middleware should be enough to do what you want. Check this : https://docs.adonisjs.com/guides/basics/middleware#middleware-execution-flow

Basically, anything called after an await next allows you to have the outgoing middleware you were describing

Replies: 2 comments 1 reply

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
1 reply
@tbarusseau
Comment options

Answer selected by tbarusseau
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Help
Labels
None yet
2 participants