Add IDs to /list results

This commit is contained in:
jude 2022-09-15 09:13:44 +01:00
parent 52327b3695
commit 5ce9ca3923
3 changed files with 7 additions and 3 deletions

2
Cargo.lock generated
View File

@ -1924,7 +1924,7 @@ dependencies = [
[[package]] [[package]]
name = "soundfx-rs" name = "soundfx-rs"
version = "1.5.4" version = "1.5.5"
dependencies = [ dependencies = [
"dashmap", "dashmap",
"env_logger", "env_logger",

View File

@ -1,6 +1,6 @@
[package] [package]
name = "soundfx-rs" name = "soundfx-rs"
version = "1.5.4" version = "1.5.5"
authors = ["jellywx <judesouthworth@pm.me>"] authors = ["jellywx <judesouthworth@pm.me>"]
edition = "2018" edition = "2018"

View File

@ -181,7 +181,11 @@ impl SoundPager {
.fields(sounds.iter().map(|s| { .fields(sounds.iter().map(|s| {
( (
s.name.as_str(), s.name.as_str(),
if s.public { "*Public*" } else { "*Private*" }, format!(
"ID: `{}`\n{}",
s.id,
if s.public { "*Public*" } else { "*Private*" }
),
true, true,
) )
})); }));