From 624407b71bdb8859f3a70c321c95ea5b1a50b16b Mon Sep 17 00:00:00 2001 From: bgaesslein Date: Sun, 13 Feb 2022 14:12:54 +0100 Subject: [PATCH] Use artist ID for primary image in constructors When using the constructor with an Album or Song, default the image to the artist ID so the artist image always shows up when set. Fixes #203 and has no side effects as far as I can see. --- app/src/main/java/com/dkanada/gramophone/model/Artist.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/app/src/main/java/com/dkanada/gramophone/model/Artist.java b/app/src/main/java/com/dkanada/gramophone/model/Artist.java index f8ff2e65..05672db2 100644 --- a/app/src/main/java/com/dkanada/gramophone/model/Artist.java +++ b/app/src/main/java/com/dkanada/gramophone/model/Artist.java @@ -46,11 +46,13 @@ public class Artist implements Parcelable { public Artist(Album album) { this.id = album.artistId; this.name = album.artistName; + this.primary = this.id; } public Artist(Song song) { this.id = song.artistId; this.name = song.artistName; + this.primary = this.id; } public Artist() {