diff --git a/CHANGELOG.md b/CHANGELOG.md index 8d3f34d..56b7606 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -14,9 +14,10 @@ - Fixed a bug where all music sources would be deleted when trying to add sources with duplicate names - Additional metadata fields are now indexed: lyricist, composer, genre and label (thanks @pmphfm) - Endpoints returning thumbnail images or audio files no longer use HTTP `content-encoding` +- When indexing files with ID3v2 tags, the "Original Date Released" frame can now be used to populate the year associated with a song - The `/thumbnail` endpoint now supports an optional parameter for small/large/native image sizing. (thanks @Saecki) - Log file now contain more details about the cause of failed HTTP requests (3xx, 4xx, 5xx) -- Startup errors emit clearer messages +- Startup failures now generate clearer error messages ### Web client diff --git a/Cargo.lock b/Cargo.lock index 82d2e83..b4dda72 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -956,8 +956,7 @@ checksum = "c4a1e36c821dbe04574f602848a19f742f4fb3c98d40449f11bcad18d6b17421" [[package]] name = "id3" version = "1.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cb0342a234e9df58f34a65b31580937414568ac60410674930939977112208f6" +source = "git+https://github.com/polyfloyd/rust-id3.git?rev=f3b5e3a#f3b5e3ac324c07c2cd5364469734ffb7a0228f77" dependencies = [ "bitflags", "byteorder", diff --git a/Cargo.toml b/Cargo.toml index 6c14d68..ceff072 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -22,7 +22,7 @@ diesel_migrations = { version = "2.0", features = ["sqlite"] } futures-util = { version = "0.3" } getopts = "0.2.21" http = "0.2.8" -id3 = "1.4.0" +id3 = { git = "https://github.com/polyfloyd/rust-id3.git", rev = "f3b5e3a" } # TODO update after 1.5.0 is released lewton = "0.10.2" libsqlite3-sys = { version = "0.25", features = ["bundled", "bundled-windows"], optional = true } log = "0.4.17" diff --git a/src/app/index/metadata.rs b/src/app/index/metadata.rs index c4d1101..f8a0a18 100644 --- a/src/app/index/metadata.rs +++ b/src/app/index/metadata.rs @@ -58,6 +58,7 @@ impl From for SongTags { .year() .map(|y| y as i32) .or_else(|| tag.date_released().map(|d| d.year)) + .or_else(|| tag.original_date_released().map(|d| d.year)) .or_else(|| tag.date_recorded().map(|d| d.year)); let has_artwork = tag.pictures().count() > 0; let lyricist = tag.get_text("TEXT");