Saving changes

This commit is contained in:
phoenix
2025-03-15 18:02:45 -04:00
parent 24d91aa4ff
commit 554be00bce
7 changed files with 76 additions and 85 deletions
+3 -3
View File
@@ -19,9 +19,9 @@ impl RetrieveRecords {
pub async fn get_all_songs(
&mut self,
token: &icarus_models::token::AccessToken,
) -> Result<Vec<models::song::Song>, Error> {
) -> Result<Vec<icarus_models::song::Song>, Error> {
self.api.endpoint = String::from("song");
let mut songs: Vec<models::song::Song> = Vec::new();
let mut songs: Vec<icarus_models::song::Song> = Vec::new();
let url = self.retrieve_url();
let access_token = token.bearer_token();
@@ -46,7 +46,7 @@ impl RetrieveRecords {
match response.status() {
reqwest::StatusCode::OK => {
// on success, parse our JSON to an APIResponse
let s = response.json::<Vec<models::song::Song>>().await;
let s = response.json::<Vec<icarus_models::song::Song>>().await;
match s {
//
Ok(parsed) => {