fix: null checking
This commit is contained in:
1 parent
a50fc74117
commit
b8b9c80bdc
1 file changed
+4
-2
@@ -63,8 +63,10 @@ public class ArtistRepository {
|
||||
if (response.isSuccessful() && response.body() != null) {
|
||||
List<ArtistID3> artists = new ArrayList<>();
|
||||
|
||||
for (IndexID3 index : response.body().getSubsonicResponse().getArtists().getIndices()) {
|
||||
artists.addAll(index.getArtists());
|
||||
if(response.body().getSubsonicResponse().getArtists() != null) {
|
||||
for (IndexID3 index : response.body().getSubsonicResponse().getArtists().getIndices()) {
|
||||
artists.addAll(index.getArtists());
|
||||
}
|
||||
}
|
||||
|
||||
if (random) {
|
||||
|
||||
Reference in new issue
Block a user