Explorar el Código

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

Kristian Vos hace 5 años
padre
commit
208bf32b70
Se han modificado 1 ficheros con 4 adiciones y 2 borrados
  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();