Browse Source

Use GetOrderBy in GetChildrenSorted

cvium 3 years ago
parent
commit
e1f7f1405e
1 changed files with 1 additions and 5 deletions
  1. 1 5
      Emby.Dlna/ContentDirectory/ControlHandler.cs

+ 1 - 5
Emby.Dlna/ContentDirectory/ControlHandler.cs

@@ -511,10 +511,6 @@ namespace Emby.Dlna.ContentDirectory
         {
         {
             var folder = (Folder)item;
             var folder = (Folder)item;
 
 
-            var sortOrders = folder.IsPreSorted
-                ? Array.Empty<(string, SortOrder)>()
-                : new[] { (ItemSortBy.SortName, sort.SortOrder) };
-
             string[] mediaTypes = Array.Empty<string>();
             string[] mediaTypes = Array.Empty<string>();
             bool? isFolder = null;
             bool? isFolder = null;
 
 
@@ -548,7 +544,7 @@ namespace Emby.Dlna.ContentDirectory
             {
             {
                 Limit = limit,
                 Limit = limit,
                 StartIndex = startIndex,
                 StartIndex = startIndex,
-                OrderBy = sortOrders,
+                OrderBy = GetOrderBy(sort, folder.IsPreSorted),
                 User = user,
                 User = user,
                 Recursive = true,
                 Recursive = true,
                 IsMissing = false,
                 IsMissing = false,