Updated some small things, extra fixes

This commit is contained in:
G2-Games 2023-10-06 01:22:55 -05:00
parent 450750f5a0
commit b39c2c0065
2 changed files with 5 additions and 4 deletions

View file

@ -74,7 +74,7 @@ impl MusicController {
self.song_control(DecoderMessage::DSP(DSPMessage::UpdateProcessor(Box::new(self.music_player.music_processor.clone()))));
}
/// Queries the library for a `Vec<Song>`
/// Queries the [MusicLibrary], returning a `Vec<Song>`
pub fn query_library(
&self,
query_string: &String,

View file

@ -420,7 +420,8 @@ impl MusicLibrary {
URI::Remote(_, path) if normalize(&path).contains(&normalize(&query_string)) => {
songs.lock().unwrap().push(track);
return
}, _ => ()
},
_ => ()
};
});
@ -477,8 +478,8 @@ impl MusicLibrary {
}
}
// If all tags are equal, sort by title
a.get_tag(&Tag::Title).cmp(&b.get_tag(&Tag::Title))
// If all tags are equal, sort by Track number
a.get_tag(&Tag::Track).cmp(&b.get_tag(&Tag::Track))
});
if new_songs.len() > 0 {