diff --git a/Emby.Server.Implementations/Sorting/AiredEpisodeOrderComparer.cs b/Emby.Server.Implementations/Sorting/AiredEpisodeOrderComparer.cs
index 037eb170a..db8b68949 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
{
+ ///
+ /// Gets the name.
+ ///
+ /// The name.
+ public string Name => ItemSortBy.AiredEpisodeOrder;
+
///
/// Compares the specified x.
///
@@ -155,11 +161,5 @@ namespace Emby.Server.Implementations.Sorting
return comparisonResult;
}
-
- ///
- /// Gets the name.
- ///
- /// The name.
- public string Name => ItemSortBy.AiredEpisodeOrder;
}
}
diff --git a/Emby.Server.Implementations/Sorting/AlbumArtistComparer.cs b/Emby.Server.Implementations/Sorting/AlbumArtistComparer.cs
index 42e644970..bd1966623 100644
--- a/Emby.Server.Implementations/Sorting/AlbumArtistComparer.cs
+++ b/Emby.Server.Implementations/Sorting/AlbumArtistComparer.cs
@@ -12,6 +12,12 @@ namespace Emby.Server.Implementations.Sorting
///
public class AlbumArtistComparer : IBaseItemComparer
{
+ ///
+ /// Gets the name.
+ ///
+ /// The name.
+ public string Name => ItemSortBy.AlbumArtist;
+
///
/// Compares the specified x.
///
@@ -34,11 +40,5 @@ namespace Emby.Server.Implementations.Sorting
return audio?.AlbumArtists.FirstOrDefault();
}
-
- ///
- /// Gets the name.
- ///
- /// The name.
- public string Name => ItemSortBy.AlbumArtist;
}
}
diff --git a/Emby.Server.Implementations/Sorting/AlbumComparer.cs b/Emby.Server.Implementations/Sorting/AlbumComparer.cs
index 1db3f5e9c..fe7dc84cb 100644
--- a/Emby.Server.Implementations/Sorting/AlbumComparer.cs
+++ b/Emby.Server.Implementations/Sorting/AlbumComparer.cs
@@ -11,6 +11,12 @@ namespace Emby.Server.Implementations.Sorting
///
public class AlbumComparer : IBaseItemComparer
{
+ ///
+ /// Gets the name.
+ ///
+ /// The name.
+ public string Name => ItemSortBy.Album;
+
///
/// Compares the specified x.
///
@@ -33,11 +39,5 @@ namespace Emby.Server.Implementations.Sorting
return audio == null ? string.Empty : audio.Album;
}
-
- ///
- /// Gets the name.
- ///
- /// The name.
- public string Name => ItemSortBy.Album;
}
}
diff --git a/Emby.Server.Implementations/Sorting/CriticRatingComparer.cs b/Emby.Server.Implementations/Sorting/CriticRatingComparer.cs
index d20dedc2d..ba1835e4f 100644
--- a/Emby.Server.Implementations/Sorting/CriticRatingComparer.cs
+++ b/Emby.Server.Implementations/Sorting/CriticRatingComparer.cs
@@ -9,6 +9,12 @@ namespace Emby.Server.Implementations.Sorting
///
public class CriticRatingComparer : IBaseItemComparer
{
+ ///
+ /// Gets the name.
+ ///
+ /// The name.
+ public string Name => ItemSortBy.CriticRating;
+
///
/// Compares the specified x.
///
@@ -24,11 +30,5 @@ namespace Emby.Server.Implementations.Sorting
{
return x?.CriticRating ?? 0;
}
-
- ///
- /// Gets the name.
- ///
- /// The name.
- public string Name => ItemSortBy.CriticRating;
}
}
diff --git a/Emby.Server.Implementations/Sorting/DateCreatedComparer.cs b/Emby.Server.Implementations/Sorting/DateCreatedComparer.cs
index d3f10f78c..8b460166c 100644
--- a/Emby.Server.Implementations/Sorting/DateCreatedComparer.cs
+++ b/Emby.Server.Implementations/Sorting/DateCreatedComparer.cs
@@ -10,6 +10,12 @@ namespace Emby.Server.Implementations.Sorting
///
public class DateCreatedComparer : IBaseItemComparer
{
+ ///
+ /// Gets the name.
+ ///
+ /// The name.
+ public string Name => ItemSortBy.DateCreated;
+
///
/// Compares the specified x.
///
@@ -30,11 +36,5 @@ namespace Emby.Server.Implementations.Sorting
return DateTime.Compare(x.DateCreated, y.DateCreated);
}
-
- ///
- /// Gets the name.
- ///
- /// The name.
- public string Name => ItemSortBy.DateCreated;
}
}
diff --git a/Emby.Server.Implementations/Sorting/DatePlayedComparer.cs b/Emby.Server.Implementations/Sorting/DatePlayedComparer.cs
index 08a44319f..ec818253b 100644
--- a/Emby.Server.Implementations/Sorting/DatePlayedComparer.cs
+++ b/Emby.Server.Implementations/Sorting/DatePlayedComparer.cs
@@ -32,6 +32,12 @@ namespace Emby.Server.Implementations.Sorting
/// The user data repository.
public IUserDataManager UserDataRepository { get; set; }
+ ///
+ /// Gets the name.
+ ///
+ /// The name.
+ public string Name => ItemSortBy.DatePlayed;
+
///
/// Compares the specified x.
///
@@ -59,11 +65,5 @@ namespace Emby.Server.Implementations.Sorting
return DateTime.MinValue;
}
-
- ///
- /// Gets the name.
- ///
- /// The name.
- public string Name => ItemSortBy.DatePlayed;
}
}
diff --git a/Emby.Server.Implementations/Sorting/NameComparer.cs b/Emby.Server.Implementations/Sorting/NameComparer.cs
index 4de81a69e..8f87717f4 100644
--- a/Emby.Server.Implementations/Sorting/NameComparer.cs
+++ b/Emby.Server.Implementations/Sorting/NameComparer.cs
@@ -10,6 +10,12 @@ namespace Emby.Server.Implementations.Sorting
///
public class NameComparer : IBaseItemComparer
{
+ ///
+ /// Gets the name.
+ ///
+ /// The name.
+ public string Name => ItemSortBy.Name;
+
///
/// Compares the specified x.
///
@@ -30,11 +36,5 @@ namespace Emby.Server.Implementations.Sorting
return string.Compare(x.Name, y.Name, StringComparison.CurrentCultureIgnoreCase);
}
-
- ///
- /// Gets the name.
- ///
- /// The name.
- public string Name => ItemSortBy.Name;
}
}
diff --git a/Emby.Server.Implementations/Sorting/PlayCountComparer.cs b/Emby.Server.Implementations/Sorting/PlayCountComparer.cs
index 04e4865cb..45c9044c5 100644
--- a/Emby.Server.Implementations/Sorting/PlayCountComparer.cs
+++ b/Emby.Server.Implementations/Sorting/PlayCountComparer.cs
@@ -19,6 +19,24 @@ namespace Emby.Server.Implementations.Sorting
/// The user.
public User User { get; set; }
+ ///
+ /// Gets the name.
+ ///
+ /// The name.
+ public string Name => ItemSortBy.PlayCount;
+
+ ///
+ /// Gets or sets the user data repository.
+ ///
+ /// The user data repository.
+ public IUserDataManager UserDataRepository { get; set; }
+
+ ///
+ /// Gets or sets the user manager.
+ ///
+ /// The user manager.
+ public IUserManager UserManager { get; set; }
+
///
/// Compares the specified x.
///
@@ -41,23 +59,5 @@ namespace Emby.Server.Implementations.Sorting
return userdata == null ? 0 : userdata.PlayCount;
}
-
- ///
- /// Gets the name.
- ///
- /// The name.
- public string Name => ItemSortBy.PlayCount;
-
- ///
- /// Gets or sets the user data repository.
- ///
- /// The user data repository.
- public IUserDataManager UserDataRepository { get; set; }
-
- ///
- /// Gets or sets the user manager.
- ///
- /// The user manager.
- public IUserManager UserManager { get; set; }
}
}
diff --git a/Emby.Server.Implementations/Sorting/PremiereDateComparer.cs b/Emby.Server.Implementations/Sorting/PremiereDateComparer.cs
index c98f97bf1..b217556ef 100644
--- a/Emby.Server.Implementations/Sorting/PremiereDateComparer.cs
+++ b/Emby.Server.Implementations/Sorting/PremiereDateComparer.cs
@@ -10,6 +10,12 @@ namespace Emby.Server.Implementations.Sorting
///
public class PremiereDateComparer : IBaseItemComparer
{
+ ///
+ /// Gets the name.
+ ///
+ /// The name.
+ public string Name => ItemSortBy.PremiereDate;
+
///
/// Compares the specified x.
///
@@ -52,11 +58,5 @@ namespace Emby.Server.Implementations.Sorting
return DateTime.MinValue;
}
-
- ///
- /// Gets the name.
- ///
- /// The name.
- public string Name => ItemSortBy.PremiereDate;
}
}
diff --git a/Emby.Server.Implementations/Sorting/ProductionYearComparer.cs b/Emby.Server.Implementations/Sorting/ProductionYearComparer.cs
index df9f9957d..d2022df7a 100644
--- a/Emby.Server.Implementations/Sorting/ProductionYearComparer.cs
+++ b/Emby.Server.Implementations/Sorting/ProductionYearComparer.cs
@@ -9,6 +9,12 @@ namespace Emby.Server.Implementations.Sorting
///
public class ProductionYearComparer : IBaseItemComparer
{
+ ///
+ /// Gets the name.
+ ///
+ /// The name.
+ public string Name => ItemSortBy.ProductionYear;
+
///
/// Compares the specified x.
///
@@ -44,11 +50,5 @@ namespace Emby.Server.Implementations.Sorting
return 0;
}
-
- ///
- /// Gets the name.
- ///
- /// The name.
- public string Name => ItemSortBy.ProductionYear;
}
}
diff --git a/Emby.Server.Implementations/Sorting/RandomComparer.cs b/Emby.Server.Implementations/Sorting/RandomComparer.cs
index af3bc2750..bf0168222 100644
--- a/Emby.Server.Implementations/Sorting/RandomComparer.cs
+++ b/Emby.Server.Implementations/Sorting/RandomComparer.cs
@@ -10,6 +10,12 @@ namespace Emby.Server.Implementations.Sorting
///
public class RandomComparer : IBaseItemComparer
{
+ ///
+ /// Gets the name.
+ ///
+ /// The name.
+ public string Name => ItemSortBy.Random;
+
///
/// Compares the specified x.
///
@@ -20,11 +26,5 @@ namespace Emby.Server.Implementations.Sorting
{
return Guid.NewGuid().CompareTo(Guid.NewGuid());
}
-
- ///
- /// Gets the name.
- ///
- /// The name.
- public string Name => ItemSortBy.Random;
}
}
diff --git a/Emby.Server.Implementations/Sorting/RuntimeComparer.cs b/Emby.Server.Implementations/Sorting/RuntimeComparer.cs
index 129315303..e32e5552e 100644
--- a/Emby.Server.Implementations/Sorting/RuntimeComparer.cs
+++ b/Emby.Server.Implementations/Sorting/RuntimeComparer.cs
@@ -12,6 +12,12 @@ namespace Emby.Server.Implementations.Sorting
///
public class RuntimeComparer : IBaseItemComparer
{
+ ///
+ /// Gets the name.
+ ///
+ /// The name.
+ public string Name => ItemSortBy.Runtime;
+
///
/// Compares the specified x.
///
@@ -32,11 +38,5 @@ namespace Emby.Server.Implementations.Sorting
return (x.RunTimeTicks ?? 0).CompareTo(y.RunTimeTicks ?? 0);
}
-
- ///
- /// Gets the name.
- ///
- /// The name.
- public string Name => ItemSortBy.Runtime;
}
}
diff --git a/Emby.Server.Implementations/Sorting/SortNameComparer.cs b/Emby.Server.Implementations/Sorting/SortNameComparer.cs
index 8d30716d3..fb97a0349 100644
--- a/Emby.Server.Implementations/Sorting/SortNameComparer.cs
+++ b/Emby.Server.Implementations/Sorting/SortNameComparer.cs
@@ -12,6 +12,12 @@ namespace Emby.Server.Implementations.Sorting
///
public class SortNameComparer : IBaseItemComparer
{
+ ///
+ /// Gets the name.
+ ///
+ /// The name.
+ public string Name => ItemSortBy.SortName;
+
///
/// Compares the specified x.
///
@@ -32,11 +38,5 @@ namespace Emby.Server.Implementations.Sorting
return string.Compare(x.SortName, y.SortName, StringComparison.CurrentCultureIgnoreCase);
}
-
- ///
- /// Gets the name.
- ///
- /// The name.
- public string Name => ItemSortBy.SortName;
}
}
diff --git a/Emby.Server.Implementations/Sorting/StudioComparer.cs b/Emby.Server.Implementations/Sorting/StudioComparer.cs
index 6826aee3b..4d89cfa8b 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
{
+ ///
+ /// Gets the name.
+ ///
+ /// The name.
+ public string Name => ItemSortBy.Studio;
+
///
/// Compares the specified x.
///
@@ -33,11 +39,5 @@ namespace Emby.Server.Implementations.Sorting
return AlphanumericComparator.CompareValues(x.Studios.FirstOrDefault(), y.Studios.FirstOrDefault());
}
-
- ///
- /// Gets the name.
- ///
- /// The name.
- public string Name => ItemSortBy.Studio;
}
}