Endpoint is now working
This commit is contained in:
@@ -562,7 +562,10 @@ pub mod endpoint {
|
|||||||
|
|
||||||
match super::cov_db::create(&pool, &coverart, &song.id).await {
|
match super::cov_db::create(&pool, &coverart, &song.id).await {
|
||||||
Ok(id) => {
|
Ok(id) => {
|
||||||
|
// TODO: Populate song_id
|
||||||
coverart.id = id;
|
coverart.id = id;
|
||||||
|
println!("Cover Art created");
|
||||||
|
|
||||||
response.message = String::from("Successful");
|
response.message = String::from("Successful");
|
||||||
response.data.push(coverart);
|
response.data.push(coverart);
|
||||||
|
|
||||||
|
|||||||
+1
-1
@@ -17,7 +17,7 @@ pub mod endpoints {
|
|||||||
|
|
||||||
pub const CREATESONG: &str = "/api/v2/song";
|
pub const CREATESONG: &str = "/api/v2/song";
|
||||||
pub const GETSONGS: &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 CREATECOVERART: &str = "/api/v2/coverart";
|
||||||
pub const GETCOVERART: &str = "/api/v2/coverart";
|
pub const GETCOVERART: &str = "/api/v2/coverart";
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user