The Free Software Media System - Server Backend & API
Fix warnings in Sorting
Patrick Barron078200d8d4ba
diff --git a/Emby.Server.Implementations/Sorting/AiredEpisodeOrderComparer.cs b/Emby.Server.Implementations/Sorting/AiredEpisodeOrderComparer.csindex 037eb170ac..db8b689491 100644--- a/Emby.Server.Implementations/Sorting/AiredEpisodeOrderComparer.cs+++ b/Emby.Server.Implementations/Sorting/AiredEpisodeOrderComparer.cs@@ -10,6 +10,12 @@ namespace Emby.Server.Implementations.Sorting{public class AiredEpisodeOrderComparer : IBaseItemComparer{+ /// <summary>+ /// Gets the name.+ /// </summary>+ /// <value>The name.</value>+ public string Name => ItemSortBy.AiredEpisodeOrder;+/// <summary>/// Compares the specified x./// </summary>@@ -155,11 +161,5 @@ namespace Emby.Server.Implementations.Sortingreturn comparisonResult;}-- /// <summary>- /// Gets the name.- /// </summary>- /// <value>The name.</value>- public string Name => ItemSortBy.AiredEpisodeOrder;}}diff --git a/Emby.Server.Implementations/Sorting/AlbumArtistComparer.cs b/Emby.Server.Implementations/Sorting/AlbumArtistComparer.csindex 42e644970c..bd19666238 100644--- a/Emby.Server.Implementations/Sorting/AlbumArtistComparer.cs+++ b/Emby.Server.Implementations/Sorting/AlbumArtistComparer.cs@@ -12,6 +12,12 @@ namespace Emby.Server.Implementations.Sorting/// </summary>public class AlbumArtistComparer : IBaseItemComparer{+ /// <summary>+ /// Gets the name.+ /// </summary>+ /// <value>The name.</value>+ public string Name => ItemSortBy.AlbumArtist;+/// <summary>/// Compares the specified x./// </summary>@@ -34,11 +40,5 @@ namespace Emby.Server.Implementations.Sortingreturn audio?.AlbumArtists.FirstOrDefault();}-- /// <summary>- /// Gets the name.- /// </summary>- /// <value>The name.</value>- public string Name => ItemSortBy.AlbumArtist;}}diff --git a/Emby.Server.Implementations/Sorting/AlbumComparer.cs b/Emby.Server.Implementations/Sorting/AlbumComparer.csindex 1db3f5e9ca..fe7dc84cbf 100644--- a/Emby.Server.Implementations/Sorting/AlbumComparer.cs+++ b/Emby.Server.Implementations/Sorting/AlbumComparer.cs@@ -11,6 +11,12 @@ namespace Emby.Server.Implementations.Sorting/// </summary>public class AlbumComparer : IBaseItemComparer{+ /// <summary>+ /// Gets the name.+ /// </summary>+ /// <value>The name.</value>+ public string Name => ItemSortBy.Album;+/// <summary>/// Compares the specified x./// </summary>@@ -33,11 +39,5 @@ namespace Emby.Server.Implementations.Sortingreturn audio == null ? string.Empty : audio.Album;}-- /// <summary>- /// Gets the name.- /// </summary>- /// <value>The name.</value>- public string Name => ItemSortBy.Album;}}diff --git a/Emby.Server.Implementations/Sorting/CriticRatingComparer.cs b/Emby.Server.Implementations/Sorting/CriticRatingComparer.csindex d20dedc2d4..ba1835e4f2 100644--- a/Emby.Server.Implementations/Sorting/CriticRatingComparer.cs+++ b/Emby.Server.Implementations/Sorting/CriticRatingComparer.cs@@ -9,6 +9,12 @@ namespace Emby.Server.Implementations.Sorting/// </summary>public class CriticRatingComparer : IBaseItemComparer{+ /// <summary>+ /// Gets the name.+ /// </summary>+ /// <value>The name.</value>+ public string Name => ItemSortBy.CriticRating;+/// <summary>/// Compares the specified x./// </summary>@@ -24,11 +30,5 @@ namespace Emby.Server.Implementations.Sorting{return x?.CriticRating ?? 0;}-- /// <summary>- /// Gets the name.- /// </summary>- /// <value>The name.</value>- public string Name => ItemSortBy.CriticRating;}}diff --git a/Emby.Server.Implementations/Sorting/DateCreatedComparer.cs b/Emby.Server.Implementations/Sorting/DateCreatedComparer.csindex d3f10f78cb..8b460166ca 100644--- a/Emby.Server.Implementations/Sorting/DateCreatedComparer.cs+++ b/Emby.Server.Implementations/Sorting/DateCreatedComparer.cs@@ -10,6 +10,12 @@ namespace Emby.Server.Implementations.Sorting/// </summary>public class DateCreatedComparer : IBaseItemComparer{+ /// <summary>+ /// Gets the name.+ /// </summary>+ /// <value>The name.</value>+ public string Name => ItemSortBy.DateCreated;+/// <summary>/// Compares the specified x./// </summary>@@ -30,11 +36,5 @@ namespace Emby.Server.Implementations.Sortingreturn DateTime.Compare(x.DateCreated, y.DateCreated);}-- /// <summary>- /// Gets the name.- /// </summary>- /// <value>The name.</value>- public string Name => ItemSortBy.DateCreated;}}diff --git a/Emby.Server.Implementations/Sorting/DatePlayedComparer.cs b/Emby.Server.Implementations/Sorting/DatePlayedComparer.csindex 08a44319f2..ec818253be 100644--- a/Emby.Server.Implementations/Sorting/DatePlayedComparer.cs+++ b/Emby.Server.Implementations/Sorting/DatePlayedComparer.cs@@ -32,6 +32,12 @@ namespace Emby.Server.Implementations.Sorting/// <value>The user data repository.</value>public IUserDataManager UserDataRepository { get; set; }+ /// <summary>+ /// Gets the name.+ /// </summary>+ /// <value>The name.</value>+ public string Name => ItemSortBy.DatePlayed;+/// <summary>/// Compares the specified x./// </summary>@@ -59,11 +65,5 @@ namespace Emby.Server.Implementations.Sortingreturn DateTime.MinValue;}-- /// <summary>- /// Gets the name.- /// </summary>- /// <value>The name.</value>- public string Name => ItemSortBy.DatePlayed;}}diff --git a/Emby.Server.Implementations/Sorting/NameComparer.cs b/Emby.Server.Implementations/Sorting/NameComparer.csindex 4de81a69e3..8f87717f49 100644--- a/Emby.Server.Implementations/Sorting/NameComparer.cs+++ b/Emby.Server.Implementations/Sorting/NameComparer.cs@@ -10,6 +10,12 @@ namespace Emby.Server.Implementations.Sorting/// </summary>public class NameComparer : IBaseItemComparer{+ /// <summary>+ /// Gets the name.+ /// </summary>+ /// <value>The name.</value>+ public string Name => ItemSortBy.Name;+/// <summary>/// Compares the specified x./// </summary>@@ -30,11 +36,5 @@ namespace Emby.Server.Implementations.Sortingreturn string.Compare(x.Name, y.Name, StringComparison.CurrentCultureIgnoreCase);}-- /// <summary>- /// Gets the name.- /// </summary>- /// <value>The name.</value>- public string Name => ItemSortBy.Name;}}diff --git a/Emby.Server.Implementations/Sorting/PlayCountComparer.cs b/Emby.Server.Implementations/Sorting/PlayCountComparer.csindex 04e4865cbf..45c9044c52 100644--- a/Emby.Server.Implementations/Sorting/PlayCountComparer.cs+++ b/Emby.Server.Implementations/Sorting/PlayCountComparer.cs@@ -19,6 +19,24 @@ namespace Emby.Server.Implementations.Sorting/// <value>The user.</value>public User User { get; set; }+ /// <summary>+ /// Gets the name.+ /// </summary>+ /// <value>The name.</value>+ public string Name => ItemSortBy.PlayCount;++ /// <summary>+ /// Gets or sets the user data repository.+ /// </summary>+ /// <value>The user data repository.</value>+ public IUserDataManager UserDataRepository { get; set; }++ /// <summary>+ /// Gets or sets the user manager.+ /// </summary>+ /// <value>The user manager.</value>+ public IUserManager UserManager { get; set; }+/// <summary>/// Compares the specified x./// </summary>@@ -41,23 +59,5 @@ namespace Emby.Server.Implementations.Sortingreturn userdata == null ? 0 : userdata.PlayCount;}-- /// <summary>- /// Gets the name.- /// </summary>- /// <value>The name.</value>- public string Name => ItemSortBy.PlayCount;-- /// <summary>- /// Gets or sets the user data repository.- /// </summary>- /// <value>The user data repository.</value>- public IUserDataManager UserDataRepository { get; set; }-- /// <summary>- /// Gets or sets the user manager.- /// </summary>- /// <value>The user manager.</value>- public IUserManager UserManager { get; set; }}}diff --git a/Emby.Server.Implementations/Sorting/PremiereDateComparer.cs b/Emby.Server.Implementations/Sorting/PremiereDateComparer.csindex c98f97bf1e..b217556ef3 100644--- a/Emby.Server.Implementations/Sorting/PremiereDateComparer.cs+++ b/Emby.Server.Implementations/Sorting/PremiereDateComparer.cs@@ -10,6 +10,12 @@ namespace Emby.Server.Implementations.Sorting/// </summary>public class PremiereDateComparer : IBaseItemComparer{+ /// <summary>+ /// Gets the name.+ /// </summary>+ /// <value>The name.</value>+ public string Name => ItemSortBy.PremiereDate;+/// <summary>/// Compares the specified x./// </summary>@@ -52,11 +58,5 @@ namespace Emby.Server.Implementations.Sortingreturn DateTime.MinValue;}-- /// <summary>- /// Gets the name.- /// </summary>- /// <value>The name.</value>- public string Name => ItemSortBy.PremiereDate;}}diff --git a/Emby.Server.Implementations/Sorting/ProductionYearComparer.cs b/Emby.Server.Implementations/Sorting/ProductionYearComparer.csindex df9f9957d6..d2022df7a6 100644--- a/Emby.Server.Implementations/Sorting/ProductionYearComparer.cs+++ b/Emby.Server.Implementations/Sorting/ProductionYearComparer.cs@@ -9,6 +9,12 @@ namespace Emby.Server.Implementations.Sorting/// </summary>public class ProductionYearComparer : IBaseItemComparer{+ /// <summary>+ /// Gets the name.+ /// </summary>+ /// <value>The name.</value>+ public string Name => ItemSortBy.ProductionYear;+/// <summary>/// Compares the specified x./// </summary>@@ -44,11 +50,5 @@ namespace Emby.Server.Implementations.Sortingreturn 0;}-- /// <summary>- /// Gets the name.- /// </summary>- /// <value>The name.</value>- public string Name => ItemSortBy.ProductionYear;}}diff --git a/Emby.Server.Implementations/Sorting/RandomComparer.cs b/Emby.Server.Implementations/Sorting/RandomComparer.csindex af3bc27508..bf0168222d 100644--- a/Emby.Server.Implementations/Sorting/RandomComparer.cs+++ b/Emby.Server.Implementations/Sorting/RandomComparer.cs@@ -10,6 +10,12 @@ namespace Emby.Server.Implementations.Sorting/// </summary>public class RandomComparer : IBaseItemComparer{+ /// <summary>+ /// Gets the name.+ /// </summary>+ /// <value>The name.</value>+ public string Name => ItemSortBy.Random;+/// <summary>/// Compares the specified x./// </summary>@@ -20,11 +26,5 @@ namespace Emby.Server.Implementations.Sorting{return Guid.NewGuid().CompareTo(Guid.NewGuid());}-- /// <summary>- /// Gets the name.- /// </summary>- /// <value>The name.</value>- public string Name => ItemSortBy.Random;}}diff --git a/Emby.Server.Implementations/Sorting/RuntimeComparer.cs b/Emby.Server.Implementations/Sorting/RuntimeComparer.csindex 1293153031..e32e5552e4 100644--- a/Emby.Server.Implementations/Sorting/RuntimeComparer.cs+++ b/Emby.Server.Implementations/Sorting/RuntimeComparer.cs@@ -12,6 +12,12 @@ namespace Emby.Server.Implementations.Sorting/// </summary>public class RuntimeComparer : IBaseItemComparer{+ /// <summary>+ /// Gets the name.+ /// </summary>+ /// <value>The name.</value>+ public string Name => ItemSortBy.Runtime;+/// <summary>/// Compares the specified x./// </summary>@@ -32,11 +38,5 @@ namespace Emby.Server.Implementations.Sortingreturn (x.RunTimeTicks ?? 0).CompareTo(y.RunTimeTicks ?? 0);}-- /// <summary>- /// Gets the name.- /// </summary>- /// <value>The name.</value>- public string Name => ItemSortBy.Runtime;}}diff --git a/Emby.Server.Implementations/Sorting/SortNameComparer.cs b/Emby.Server.Implementations/Sorting/SortNameComparer.csindex 8d30716d39..fb97a0349d 100644--- a/Emby.Server.Implementations/Sorting/SortNameComparer.cs+++ b/Emby.Server.Implementations/Sorting/SortNameComparer.cs@@ -12,6 +12,12 @@ namespace Emby.Server.Implementations.Sorting/// </summary>public class SortNameComparer : IBaseItemComparer{+ /// <summary>+ /// Gets the name.+ /// </summary>+ /// <value>The name.</value>+ public string Name => ItemSortBy.SortName;+/// <summary>/// Compares the specified x./// </summary>@@ -32,11 +38,5 @@ namespace Emby.Server.Implementations.Sortingreturn string.Compare(x.SortName, y.SortName, StringComparison.CurrentCultureIgnoreCase);}-- /// <summary>- /// Gets the name.- /// </summary>- /// <value>The name.</value>- public string Name => ItemSortBy.SortName;}}diff --git a/Emby.Server.Implementations/Sorting/StudioComparer.cs b/Emby.Server.Implementations/Sorting/StudioComparer.csindex 6826aee3b1..4d89cfa8b2 100644--- a/Emby.Server.Implementations/Sorting/StudioComparer.cs+++ b/Emby.Server.Implementations/Sorting/StudioComparer.cs@@ -13,6 +13,12 @@ namespace Emby.Server.Implementations.Sorting{public class StudioComparer : IBaseItemComparer{+ /// <summary>+ /// Gets the name.+ /// </summary>+ /// <value>The name.</value>+ public string Name => ItemSortBy.Studio;+/// <summary>/// Compares the specified x./// </summary>@@ -33,11 +39,5 @@ namespace Emby.Server.Implementations.Sortingreturn AlphanumericComparator.CompareValues(x.Studios.FirstOrDefault(), y.Studios.FirstOrDefault());}-- /// <summary>- /// Gets the name.- /// </summary>- /// <value>The name.</value>- public string Name => ItemSortBy.Studio;}}