Fixed #215
authorRemixDev <deezloaderremix@gmail.com>
Sat, 9 Mar 2019 15:59:36 +0000 (16:59 +0100)
committerRemixDev <deezloaderremix@gmail.com>
Sat, 9 Mar 2019 15:59:36 +0000 (16:59 +0100)
app/app.js

index 4a3bd5f7aeb97b7ea1cc141f4c8029572e07d7ec..d9b256bffd4cbcfdebecd6d7d43e6c08e8a934c3 100644 (file)
@@ -1297,12 +1297,14 @@ io.sockets.on('connection', function (s) {
                                        track.album.artist.picture = track.artist.picture
                                }else{
                                        let found = false
-                                       track.artists.forEach(x=>{
-                                               if(!found && x.name == track.album.artist.name){
-                                                       track.album.artist.picture = x.picture
-                                                       found = true
-                                               }
-                                       })
+                                       if (track.artists){
+                                               track.artists.forEach(x=>{
+                                                       if(!found && x.name == track.album.artist.name){
+                                                               track.album.artist.picture = x.picture
+                                                               found = true
+                                                       }
+                                               })
+                                       }
                                        if(settings.saveArtworkArtist && !found){
                                                artist = await s.Deezer.legacyGetArtist(track.album.artist.id)
                                                track.album.artist.picture = artist.picture_small.split("/56x56-000000-80-0-0.jpg")[0].split(s.Deezer.artistPictureHost)[1]