Skip to content

Error result of an endpoint still returns Outcome::Success #2928

Answered by the10thWiz
Andynopol asked this question in Questions
Discussion options

You must be logged in to vote

I'm not sure what docs you were reading, but according to https://rocket.rs/guide/v0.5/responses/#result, Result just delegates the response to the Ok or Err type. The reason the endpoint as a whole returns Outcome::Sucess, is because it successfully generates a response (even if that response is a 4XX or 5XX response).

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by Andynopol
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants