diff --git a/src/loota.rs b/src/loota.rs index a9aceb1..67a95a7 100644 --- a/src/loota.rs +++ b/src/loota.rs @@ -219,19 +219,10 @@ async fn get_admin_orders() -> impl Responder { .content_type(APPLICATION_JSON) .json(response), - Ok(Err(diesel_error)) => { - println!("Diesel error: {:?}", diesel_error); - HttpResponse::InternalServerError() - .content_type(APPLICATION_JSON) - .body("Database query failed") - } - - Err(blocking_error) => { - println!("Blocking error: {:?}", blocking_error); - HttpResponse::InternalServerError() - .content_type(APPLICATION_JSON) - .body("Server thread blocking error") - } + _ => HttpResponse::NotFound() + .content_type(APPLICATION_JSON) + .await + .unwrap(), } }