Compare commits
2 Commits
v0.6.6-65-
...
f02793e9bd
Author | SHA1 | Date | |
---|---|---|---|
f02793e9bd
|
|||
290db5ce10
|
2
Cargo.lock
generated
2
Cargo.lock
generated
@@ -142,7 +142,7 @@ checksum = "5971ac85611da7067dbfcabef3c70ebb5606018acd9e2a3903a0da507521e0d5"
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "icarus_models"
|
name = "icarus_models"
|
||||||
version = "0.6.6"
|
version = "0.6.5"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"josekit",
|
"josekit",
|
||||||
"rand",
|
"rand",
|
||||||
|
@@ -1,6 +1,6 @@
|
|||||||
[package]
|
[package]
|
||||||
name = "icarus_models"
|
name = "icarus_models"
|
||||||
version = "0.6.6"
|
version = "0.6.5"
|
||||||
edition = "2024"
|
edition = "2024"
|
||||||
rust-version = "1.88"
|
rust-version = "1.88"
|
||||||
description = "models used for the icarus project"
|
description = "models used for the icarus project"
|
||||||
|
@@ -39,20 +39,7 @@ impl CoverArt {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Removes the coverart from the filesystem
|
// TODO: Add method to remove from filesystem
|
||||||
pub fn remove_from_filesystem(&self) -> Result<(), std::io::Error> {
|
|
||||||
let p = std::path::Path::new(&self.path);
|
|
||||||
if p.exists() {
|
|
||||||
match std::fs::remove_file(p) {
|
|
||||||
Ok(_) => Ok(()),
|
|
||||||
Err(err) => Err(err),
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
Err(std::io::Error::other(
|
|
||||||
"Cannot delete file that does not exist",
|
|
||||||
))
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
pub mod io {
|
pub mod io {
|
||||||
|
@@ -118,9 +118,7 @@ impl Song {
|
|||||||
Err(err) => Err(err),
|
Err(err) => Err(err),
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
Err(std::io::Error::other(
|
Ok(())
|
||||||
"Cannot delete file that does not exist",
|
|
||||||
))
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Err(err) => Err(err),
|
Err(err) => Err(err),
|
||||||
|
Reference in New Issue
Block a user