clippy: adhere to pedantic clippy, uniform test error handling

This commit is contained in:
Per Stark
2026-05-26 11:43:45 +02:00
parent 6a5d631287
commit 000852c94c
68 changed files with 2468 additions and 2547 deletions
+3 -3
View File
@@ -1,12 +1,12 @@
use axum::{extract::State, response::IntoResponse, Extension, Json};
use common::storage::types::user::User;
use crate::{api_state::ApiState, error::ApiError};
use crate::{api_state::ApiState, error::ApiErr};
pub async fn get_categories(
pub async fn list(
State(state): State<ApiState>,
Extension(user): Extension<User>,
) -> Result<impl IntoResponse, ApiError> {
) -> Result<impl IntoResponse, ApiErr> {
let categories = User::get_user_categories(&user.id, &state.db).await?;
Ok(Json(categories))
+1 -1
View File
@@ -13,7 +13,7 @@ use serde_json::json;
use tempfile::NamedTempFile;
use tracing::info;
use crate::{api_state::ApiState, error::ApiError};
use crate::{api_state::ApiState, error::ApiErr};
#[derive(Debug, TryFromMultipart)]
pub struct IngestParams {