Refactoring (#31)

* Refactoring code

* Code formatting

* More changes

* Moved to icarus-models::user

* Some refactoring

* Updated icarus-models

* Removing constants

* Replaced with icarus-models constants

* Formatting

* Switched to constants from icarus-models:

* Replaced Token with AccessToken from icarus-models

* Updated icarus-models

* Formatting

* Removing code
This commit was merged in pull request #31.
This commit is contained in:
KD
2025-03-13 21:40:22 -04:00
committed by GitHub
parent a372bfcc05
commit c575d2e523
18 changed files with 105 additions and 169 deletions
+2 -4
View File
@@ -3,8 +3,6 @@ use std::io::Read;
use serde::{Deserialize, Serialize};
use crate::constants;
#[derive(Clone, Debug, Deserialize, Serialize)]
pub struct Song {
#[serde(alias = "id")]
@@ -127,9 +125,9 @@ impl Song {
filename += &self.track.unwrap().to_string();
if i_type == 0 {
filename += constants::file_extensions::_MP3_FILE_EXTENSION;
filename += icarus_models::constants::MPTHREE_EXTENSION;
} else {
filename += constants::file_extensions::WAV_FILE_EXTENSION;
filename += icarus_models::constants::WAV_EXTENSION;
}
self.filename = Some(filename);