Просмотр исходного кода

Fixed issue with playlist mode

Kristian Vos 4 лет назад
Родитель
Сommit
c4d7280ce1
1 измененных файлов с 5 добавлено и 1 удалено
  1. 5 1
      backend/logic/stations.js

+ 5 - 1
backend/logic/stations.js

@@ -513,7 +513,11 @@ class _StationsModule extends CoreClass {
 								if (songsToAdd.length >= songsStillNeeded) return false;
 								return true;
 							});
-						next(null, [...currentSongs, ...songsToAdd]);
+						const newPlaylist = [...currentSongs, ...songsToAdd].map(song => {
+							if (!song._id) song._id = null;
+							return song;
+						});
+						next(null, newPlaylist);
 					},
 
 					(newPlaylist, next) => {