The Free Software Media System - Server Backend & API
filter items on library changed
Luke Pulverenti37c1c8626f98
diff --git a/MediaBrowser.ServerApplication/EntryPoints/WebSocketEvents.cs b/MediaBrowser.ServerApplication/EntryPoints/WebSocketEvents.csindex a4a43509d3..5e0a477f3a 100644--- a/MediaBrowser.ServerApplication/EntryPoints/WebSocketEvents.cs+++ b/MediaBrowser.ServerApplication/EntryPoints/WebSocketEvents.cs@@ -272,8 +272,13 @@ namespace MediaBrowser.ServerApplication.EntryPoints{// Remove dupes in case some were saved multiple timesLibraryUpdateInfo.FoldersAddedTo = LibraryUpdateInfo.FoldersAddedTo.Distinct().ToList();+LibraryUpdateInfo.FoldersRemovedFrom = LibraryUpdateInfo.FoldersRemovedFrom.Distinct().ToList();- LibraryUpdateInfo.ItemsUpdated = LibraryUpdateInfo.ItemsUpdated.Distinct().ToList();++ LibraryUpdateInfo.ItemsUpdated = LibraryUpdateInfo.ItemsUpdated+ .Where(i => !LibraryUpdateInfo.ItemsAdded.Contains(i))+ .Distinct()+ .ToList();_serverManager.SendWebSocketMessage("LibraryChanged", LibraryUpdateInfo);