Sfoglia il codice sorgente

fix: notify to station that private playlist is no longer selected on remove

Kristian Vos 5 anni fa
parent
commit
208bf32b70
1 ha cambiato i file con 4 aggiunte e 2 eliminazioni
  1. 4 2
      backend/logic/actions/playlists.js

+ 4 - 2
backend/logic/actions/playlists.js

@@ -649,8 +649,10 @@ let lib = {
 							},
 
 							(res, next) => {
-								if (!station.partyMode) moduleManager.modules["stations"].updateStation(station._id, next);
-								else next();
+								if (!station.partyMode) {
+									moduleManager.modules["stations"].updateStation(station._id, next);
+									cache.pub('privatePlaylist.selected', { playlistId: null, stationId: station._id });
+								} else next();
 							}
 						], (err) => {
 							next();