diff --git a/MediaBrowser.Controller/Entities/UserView.cs b/MediaBrowser.Controller/Entities/UserView.cs index 2379326a1..df089b5b2 100644 --- a/MediaBrowser.Controller/Entities/UserView.cs +++ b/MediaBrowser.Controller/Entities/UserView.cs @@ -164,6 +164,18 @@ namespace MediaBrowser.Controller.Entities return types.Contains(viewType ?? string.Empty, StringComparer.OrdinalIgnoreCase); } + public static bool EnableOriginalFolder(string viewType) + { + var types = new[] + { + CollectionType.Games, + CollectionType.Books, + CollectionType.MusicVideos + }; + + return types.Contains(viewType ?? string.Empty, StringComparer.OrdinalIgnoreCase); + } + protected override Task ValidateChildrenInternal(IProgress progress, System.Threading.CancellationToken cancellationToken, bool recursive, bool refreshChildMetadata, Providers.MetadataRefreshOptions refreshOptions, Providers.IDirectoryService directoryService) { return Task.FromResult(true); diff --git a/MediaBrowser.Server.Implementations/Library/UserViewManager.cs b/MediaBrowser.Server.Implementations/Library/UserViewManager.cs index 98a375923..7d28be7ff 100644 --- a/MediaBrowser.Server.Implementations/Library/UserViewManager.cs +++ b/MediaBrowser.Server.Implementations/Library/UserViewManager.cs @@ -90,7 +90,7 @@ namespace MediaBrowser.Server.Implementations.Library { list.Add(await GetUserView(folder, folderViewType, false, string.Empty, cancellationToken).ConfigureAwait(false)); } - else if (_config.Configuration.EnableSharedCollectionViewImage) + else if (_config.Configuration.EnableSharedCollectionViewImage || UserView.EnableOriginalFolder(folderViewType)) { list.Add(folder); } @@ -110,6 +110,10 @@ namespace MediaBrowser.Server.Implementations.Library { list.Add(await GetUserView(folder.Id, folder.Name, folderViewType, false, string.Empty, user, cancellationToken).ConfigureAwait(false)); } + else if (_config.Configuration.EnableSharedCollectionViewImage || UserView.EnableOriginalFolder(folderViewType)) + { + list.Add(folder); + } else if (!string.IsNullOrWhiteSpace(folderViewType)) { list.Add(await GetUserView(folder.Id, folder.Name, folderViewType, true, string.Empty, user, cancellationToken).ConfigureAwait(false));