From 4c5ea9070f68c15447d3fac961f9c3ef9b5a0265 Mon Sep 17 00:00:00 2001 From: Luke Pulverenti Date: Fri, 13 Nov 2015 15:54:04 -0500 Subject: [PATCH] add master changes --- .../Persistence/CleanDatabaseScheduledTask.cs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/MediaBrowser.Server.Implementations/Persistence/CleanDatabaseScheduledTask.cs b/MediaBrowser.Server.Implementations/Persistence/CleanDatabaseScheduledTask.cs index 899b8ea29b..dd96b97905 100644 --- a/MediaBrowser.Server.Implementations/Persistence/CleanDatabaseScheduledTask.cs +++ b/MediaBrowser.Server.Implementations/Persistence/CleanDatabaseScheduledTask.cs @@ -149,7 +149,7 @@ namespace MediaBrowser.Server.Implementations.Persistence if (item != null) { - _logger.Debug("Cleaning item {0} type: {1} path: {2}", item.Name, item.GetType().Name, item.Path ?? string.Empty); + _logger.Info("Cleaning item {0} type: {1} path: {2}", item.Name, item.GetType().Name, item.Path ?? string.Empty); await _libraryManager.DeleteItem(item, new DeleteOptions { @@ -170,7 +170,6 @@ namespace MediaBrowser.Server.Implementations.Persistence { var result = _itemRepo.GetItemIdsWithPath(new InternalItemsQuery { - IsOffline = false, LocationType = LocationType.FileSystem, //Limit = limit, @@ -214,6 +213,8 @@ namespace MediaBrowser.Server.Implementations.Persistence continue; } + _logger.Info("Deleting item from database {0} because path no longer exists. type: {1} path: {2}", libraryItem.Name, libraryItem.GetType().Name, libraryItem.Path ?? string.Empty); + await _libraryManager.DeleteItem(libraryItem, new DeleteOptions { DeleteFileLocation = false