feat: implement ToSchema for ItemQuery and ItemContentQuery

Co-authored-by: aider (openai/andrew/openrouter/deepseek/deepseek-chat-v3.1) <aider@aider.chat>
This commit is contained in:
Andrew Phillips
2025-08-28 17:29:35 -03:00
parent efabb9c3ca
commit 34642abaf9
2 changed files with 3 additions and 4 deletions

View File

@@ -120,7 +120,7 @@ pub struct ListItemsQuery {
pub count: Option<u32>, pub count: Option<u32>,
} }
#[derive(Debug, Deserialize)] #[derive(Debug, Deserialize, utoipa::ToSchema)]
pub struct ItemQuery { pub struct ItemQuery {
#[serde(default = "default_allow_binary")] #[serde(default = "default_allow_binary")]
pub allow_binary: bool, pub allow_binary: bool,
@@ -130,7 +130,7 @@ pub struct ItemQuery {
pub length: u64, pub length: u64,
} }
#[derive(Debug, Deserialize)] #[derive(Debug, Deserialize, utoipa::ToSchema)]
pub struct ItemContentQuery { pub struct ItemContentQuery {
pub tags: Option<String>, pub tags: Option<String>,
#[serde(default = "default_allow_binary")] #[serde(default = "default_allow_binary")]

View File

@@ -5,7 +5,6 @@ use crate::compression_engine::CompressionType;
use clap::Command; use clap::Command;
use std::path::PathBuf; use std::path::PathBuf;
use std::str::FromStr; use std::str::FromStr;
use strum::IntoEnumIterator;
pub struct StatusService; pub struct StatusService;
@@ -31,7 +30,7 @@ impl StatusService {
Some(crate::compression_engine::default_compression_type()) Some(crate::compression_engine::default_compression_type())
}; };
let mut status_info = generate_status_info(data_path, db_path, &meta_plugin_types, enabled_compression_type); let status_info = generate_status_info(data_path, db_path, &meta_plugin_types, enabled_compression_type);
// The options are now populated directly in generate_status_info // The options are now populated directly in generate_status_info
// No need to modify them here // No need to modify them here