Przeglądaj źródła

update suggestions

Luke Pulverenti 7 lat temu
rodzic
commit
0bc3cdfab7

+ 1 - 1
Emby.Server.Implementations/Data/SqliteItemRepository.cs

@@ -3038,8 +3038,8 @@ namespace Emby.Server.Implementations.Data
             {
                 if (orderBy.Count == 0)
                 {
-                    orderBy.Add(new Tuple<string, SortOrder>(ItemSortBy.Random, SortOrder.Ascending));
                     orderBy.Add(new Tuple<string, SortOrder>("SimilarityScore", SortOrder.Descending));
+                    orderBy.Add(new Tuple<string, SortOrder>(ItemSortBy.Random, SortOrder.Ascending));
                     //orderBy.Add(new Tuple<string, SortOrder>(ItemSortBy.Random, SortOrder.Ascending));
                 }
             }

+ 2 - 0
Emby.Server.Implementations/Devices/SqliteDeviceRepository.cs

@@ -83,6 +83,8 @@ namespace Emby.Server.Implementations.Devices
                 {
                     var device = _json.DeserializeFromFile<DeviceInfo>(file);
 
+                    device.Name = string.IsNullOrWhiteSpace(device.CustomName) ? device.ReportedName : device.CustomName;
+
                     SaveDevice(device);
                 }
                 catch (Exception ex)