From 674b58e2905acb5edf633531a689dd85d74f8dba Mon Sep 17 00:00:00 2001 From: Ethan Girouard Date: Sat, 27 Jun 2026 15:17:02 -0400 Subject: [PATCH] Use wildcard match for Error variants without special status codes --- src/util/error.rs | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/util/error.rs b/src/util/error.rs index 61e9470..95f8f4b 100644 --- a/src/util/error.rs +++ b/src/util/error.rs @@ -242,9 +242,8 @@ impl dioxus_fullstack::AsStatusCode for Error { ErrorType::Database(msg) if *msg == (diesel::result::Error::NotFound).to_string() => { StatusCode::NOT_FOUND } - ErrorType::Database(_) => StatusCode::INTERNAL_SERVER_ERROR, - ErrorType::Error(_) => StatusCode::INTERNAL_SERVER_ERROR, ErrorType::ServerFnError(e) => e.as_status_code(), + _ => StatusCode::INTERNAL_SERVER_ERROR, } } }