diff --git a/MediaBrowser.Model/Entities/LibraryUpdateInfo.cs b/MediaBrowser.Model/Entities/LibraryUpdateInfo.cs
index ae85cbc3e2..dca8cd5845 100644
--- a/MediaBrowser.Model/Entities/LibraryUpdateInfo.cs
+++ b/MediaBrowser.Model/Entities/LibraryUpdateInfo.cs
@@ -9,10 +9,15 @@ namespace MediaBrowser.Model.Entities
public class LibraryUpdateInfo
{
///
- /// Gets or sets the folders.
+ /// Gets or sets the folders added to.
///
- /// The folders.
- public List Folders { get; set; }
+ /// The folders added to.
+ public List FoldersAddedTo { get; set; }
+ ///
+ /// Gets or sets the folders removed from.
+ ///
+ /// The folders removed from.
+ public List FoldersRemovedFrom { get; set; }
///
/// Gets or sets the items added.
@@ -37,7 +42,8 @@ namespace MediaBrowser.Model.Entities
///
public LibraryUpdateInfo()
{
- Folders = new List();
+ FoldersAddedTo = new List();
+ FoldersRemovedFrom = new List();
ItemsAdded = new List();
ItemsRemoved = new List();
ItemsUpdated = new List();
diff --git a/MediaBrowser.ServerApplication/EntryPoints/WebSocketEvents.cs b/MediaBrowser.ServerApplication/EntryPoints/WebSocketEvents.cs
index 006e78bc76..1ba4232d38 100644
--- a/MediaBrowser.ServerApplication/EntryPoints/WebSocketEvents.cs
+++ b/MediaBrowser.ServerApplication/EntryPoints/WebSocketEvents.cs
@@ -194,7 +194,7 @@ namespace MediaBrowser.ServerApplication.EntryPoints
if (e.Item.Parent != null)
{
- LibraryUpdateInfo.Folders.Add(e.Item.Parent.Id);
+ LibraryUpdateInfo.FoldersAddedTo.Add(e.Item.Parent.Id);
}
LibraryUpdateInfo.ItemsAdded.Add(e.Item.Id);
@@ -225,11 +225,6 @@ namespace MediaBrowser.ServerApplication.EntryPoints
LibraryUpdateTimer.Change(LibraryUpdateDuration, Timeout.Infinite);
}
- if (e.Item.Parent != null)
- {
- LibraryUpdateInfo.Folders.Add(e.Item.Parent.Id);
- }
-
LibraryUpdateInfo.ItemsUpdated.Add(e.Item.Id);
}
}
@@ -260,7 +255,7 @@ namespace MediaBrowser.ServerApplication.EntryPoints
if (e.Item.Parent != null)
{
- LibraryUpdateInfo.Folders.Add(e.Item.Parent.Id);
+ LibraryUpdateInfo.FoldersRemovedFrom.Add(e.Item.Parent.Id);
}
LibraryUpdateInfo.ItemsRemoved.Add(e.Item.Id);
@@ -276,7 +271,8 @@ namespace MediaBrowser.ServerApplication.EntryPoints
lock (_libraryChangedSyncLock)
{
// Remove dupes in case some were saved multiple times
- LibraryUpdateInfo.Folders = LibraryUpdateInfo.Folders.Distinct().ToList();
+ LibraryUpdateInfo.FoldersAddedTo = LibraryUpdateInfo.FoldersAddedTo.Distinct().ToList();
+ LibraryUpdateInfo.FoldersRemovedFrom = LibraryUpdateInfo.FoldersRemovedFrom.Distinct().ToList();
LibraryUpdateInfo.ItemsUpdated = LibraryUpdateInfo.ItemsUpdated.Distinct().ToList();
_serverManager.SendWebSocketMessage("LibraryChanged", LibraryUpdateInfo);