This commit is contained in:
Matthew Pomes 2024-07-01 00:29:16 -05:00
parent eaea6f6b57
commit 1308c1903d
No known key found for this signature in database
GPG Key ID: B8C0D93B8D8FBDB7
1 changed files with 3 additions and 1 deletions

View File

@ -57,7 +57,9 @@ fn hello_not_found(req: &Request<'_>) -> content::RawHtml<String> {
// NOTE: right now, the error must be the first parameter, and all three params must
// be present. I'm thinking about adding a param to the macro to indicate which (and whether)
// param is a downcast error.
#[catch(422)]
// `error` and `status` type. All other params must be `FromRequest`?
#[catch(422, error = "<e>" /*, status = "<_s>"*/)]
fn param_error(e: &IntErr, _s: Status, req: &Request<'_>) -> content::RawHtml<String> {
content::RawHtml(format!("\
<p>Sorry, but '{}' is not a valid path!</p>\