INNER CODE UNIT · Rust

Some

xiaobaimc/myune_music · rust/src/api/audio_info.rs:103

            if let Some(pic) = tag.pictures().first() {
                info.cover = Some(pic.data().to_vec());
            }
        }

        if options.need_lyrics {
            info.lyrics = tag
                .get_string(ItemKey::Lyrics)
                .or_else(|| tag.get_string(ItemKey::UnsyncLyrics)) // UnsyncLyrics 应该作为兜底
                .map(|s| s.to_string());
        }

        if options.need_extra_tags {
            info.year = tag
                .get_string(ItemKey::Year)
                .and_then(|y| y.parse::<u32>().ok());

            if let Some(genre_str) = tag.genre() {

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…