Skip to content

How can I gracefully responds as 413 when DefaultBodyLimit fails? #1847

Answered by davidpdrsn
AcrylicShrimp asked this question in Q&A
Discussion options

You must be logged in to vote

Yeah I agree that's a lot of code to write. I guess it makes implement IntoResponse for MultipartError. It should probably also have status_code and body_text methods like all rejections have (https://docs.rs/axum/latest/axum/extract/multipart/enum.MultipartRejection.html#method.body_text)

I've filed an issue for it #1851

Replies: 1 comment

Comment options

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