From c1672968ca46e4c2660a1b81161876786b58ec09 Mon Sep 17 00:00:00 2001 From: kdeng00 Date: Sun, 27 Jul 2025 13:27:48 -0400 Subject: [PATCH] Endpoint is now working --- src/callers/coverart.rs | 3 +++ src/callers/mod.rs | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/src/callers/coverart.rs b/src/callers/coverart.rs index 31f8045..7a3398a 100644 --- a/src/callers/coverart.rs +++ b/src/callers/coverart.rs @@ -562,7 +562,10 @@ pub mod endpoint { match super::cov_db::create(&pool, &coverart, &song.id).await { Ok(id) => { + // TODO: Populate song_id coverart.id = id; + println!("Cover Art created"); + response.message = String::from("Successful"); response.data.push(coverart); diff --git a/src/callers/mod.rs b/src/callers/mod.rs index 8fb79b6..b04f7a2 100644 --- a/src/callers/mod.rs +++ b/src/callers/mod.rs @@ -17,7 +17,7 @@ pub mod endpoints { pub const CREATESONG: &str = "/api/v2/song"; pub const GETSONGS: &str = "/api/v2/song"; - pub const STREAMSONG: &str = "/api/v2/song/stream"; + pub const STREAMSONG: &str = "/api/v2/song/stream/{id}"; pub const CREATECOVERART: &str = "/api/v2/coverart"; pub const GETCOVERART: &str = "/api/v2/coverart"; }