mirror of
https://github.com/Dummi26/musicdb.git
synced 2025-03-10 05:43:53 +01:00
[filldb] fix symlink album covers + update id3
This commit is contained in:
parent
4996cc2e27
commit
a8e18abfd2
@ -6,6 +6,6 @@ edition = "2021"
|
||||
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
|
||||
|
||||
[dependencies]
|
||||
id3 = "1.7.0"
|
||||
id3 = "1.16.0"
|
||||
mp3-duration = "0.1.10"
|
||||
musicdb-lib = { version = "0.1.0", path = "../musicdb-lib" }
|
||||
|
@ -434,9 +434,9 @@ fn get_cover(
|
||||
if let Ok(files) = fs::read_dir(&abs_dir) {
|
||||
for file in files {
|
||||
if let Ok(file) = file {
|
||||
if let Ok(metadata) = file.metadata() {
|
||||
if metadata.is_file() {
|
||||
let path = file.path();
|
||||
if let Ok(metadata) = path.metadata() {
|
||||
if metadata.is_file() {
|
||||
if path.extension().and_then(|v| v.to_str()).is_some_and(|v| {
|
||||
matches!(v.to_lowercase().as_str(), "png" | "jpg" | "jpeg")
|
||||
}) {
|
||||
|
Loading…
Reference in New Issue
Block a user