cargo clippy
Some checks failed
Build and test / build (push) Successful in 1m3s
Build and test / check (push) Failing after 1m24s
Build and test / test (push) Successful in 1m50s
Build and test / docs (push) Successful in 1m14s

This commit is contained in:
2025-12-08 01:08:58 +09:00
parent 955fdbcff1
commit 4bb5702eba
2 changed files with 10 additions and 13 deletions

View File

@@ -1,7 +1,7 @@
use serde::{Deserialize, Serialize};
use crate::{
DbSongInfo, Priority, SongId, SongPosition,
DbSongInfo,
commands::{Command, CommandRequest, CommandResponse, RequestParserError, ResponseParserError},
common::types::{PlaylistName, WindowRange},
request_tokenizer::RequestTokenizer,

View File

@@ -62,18 +62,15 @@ impl FromStr for Sort {
impl Display for Sort {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match self {
Sort { descending, key } => {
if *descending {
write!(f, "-")?;
}
match key {
SortKey::LastModified => write!(f, "last-modified"),
SortKey::Added => write!(f, "added"),
SortKey::Prio => write!(f, "prio"),
SortKey::Tag(tag) => write!(f, "{}", tag),
}
}
let Sort { descending, key } = self;
if *descending {
write!(f, "-")?;
}
match key {
SortKey::LastModified => write!(f, "last-modified"),
SortKey::Added => write!(f, "added"),
SortKey::Prio => write!(f, "prio"),
SortKey::Tag(tag) => write!(f, "{}", tag),
}
}
}