Only set an album image ID if it is null.
authorDavid ‘Bombe’ Roden <bombe@pterodactylus.net>
Fri, 23 Sep 2011 09:42:35 +0000 (11:42 +0200)
committerDavid ‘Bombe’ Roden <bombe@pterodactylus.net>
Fri, 23 Sep 2011 09:42:35 +0000 (11:42 +0200)
src/main/java/net/pterodactylus/sone/data/Album.java

index 2bbbb57..56bddb2 100644 (file)
@@ -180,7 +180,7 @@ public class Album implements Fingerprintable {
                        image.getAlbum().removeImage(image);
                }
                image.setAlbum(this);
-               if (imageIds.isEmpty()) {
+               if (imageIds.isEmpty() && (albumImage == null)) {
                        albumImage = image.getId();
                }
                if (!imageIds.contains(image.getId())) {