From 845c4a0d62e05b89d0a8bc3900b54e3c2cb75168 Mon Sep 17 00:00:00 2001 From: Luke Pulverenti Date: Thu, 18 Aug 2016 11:13:18 -0400 Subject: update item by name validators --- MediaBrowser.Api/UserLibrary/ItemsService.cs | 19 +------------------ 1 file changed, 1 insertion(+), 18 deletions(-) (limited to 'MediaBrowser.Api/UserLibrary/ItemsService.cs') diff --git a/MediaBrowser.Api/UserLibrary/ItemsService.cs b/MediaBrowser.Api/UserLibrary/ItemsService.cs index 97a81b790..9194cdb35 100644 --- a/MediaBrowser.Api/UserLibrary/ItemsService.cs +++ b/MediaBrowser.Api/UserLibrary/ItemsService.cs @@ -157,24 +157,7 @@ namespace MediaBrowser.Api.UserLibrary folder = user == null ? _libraryManager.RootFolder : _libraryManager.GetUserRootFolder(); } - if (!string.IsNullOrEmpty(request.Ids)) - { - request.Recursive = true; - var query = GetItemsQuery(request, user); - var result = await folder.GetItems(query).ConfigureAwait(false); - - if (string.IsNullOrWhiteSpace(request.SortBy)) - { - var ids = query.ItemIds.ToList(); - - // Try to preserve order - result.Items = result.Items.OrderBy(i => ids.IndexOf(i.Id.ToString("N"))).ToArray(); - } - - return result; - } - - if (request.Recursive) + if (request.Recursive || !string.IsNullOrEmpty(request.Ids)) { return await folder.GetItems(GetItemsQuery(request, user)).ConfigureAwait(false); } -- cgit v1.2.3