Reuse sorting methods
This commit is contained in:
parent
bd8dd8bae5
commit
67fb3fa54b
@ -855,13 +855,8 @@ impl<LIB, DB> MusicHoard<LIB, DB> {
|
||||
music_hoard_unique_url_dispatch!(qobuz);
|
||||
|
||||
fn sort(collection: &mut [Artist]) {
|
||||
collection.sort_unstable();
|
||||
for artist in collection.iter_mut() {
|
||||
artist.albums.sort_unstable();
|
||||
for album in artist.albums.iter_mut() {
|
||||
album.tracks.sort_unstable();
|
||||
}
|
||||
}
|
||||
Self::sort_artists(collection);
|
||||
Self::sort_albums_and_tracks(collection);
|
||||
}
|
||||
|
||||
fn sort_artists(collection: &mut [Artist]) {
|
||||
|
Loading…
Reference in New Issue
Block a user