aboutsummaryrefslogtreecommitdiff
path: root/Emby.Server.Implementations/Sorting
diff options
context:
space:
mode:
authorLuke <luke.pulverenti@gmail.com>2017-04-07 15:26:59 -0400
committerGitHub <noreply@github.com>2017-04-07 15:26:59 -0400
commit7c55cd08cbfc1c4a6ba2823007432316e1efce8d (patch)
treeb045a71d84deeb89a85975d34a7a2ded2642c0d5 /Emby.Server.Implementations/Sorting
parent66e901ef93942c631c3ee3b222cc75265e1b17fb (diff)
parent6f7d8bb742f3594bdca16fa5c20c55707edad158 (diff)
Merge pull request #2567 from MediaBrowser/beta
Beta
Diffstat (limited to 'Emby.Server.Implementations/Sorting')
-rw-r--r--Emby.Server.Implementations/Sorting/MetascoreComparer.cs41
1 files changed, 0 insertions, 41 deletions
diff --git a/Emby.Server.Implementations/Sorting/MetascoreComparer.cs b/Emby.Server.Implementations/Sorting/MetascoreComparer.cs
deleted file mode 100644
index 9759e0228..000000000
--- a/Emby.Server.Implementations/Sorting/MetascoreComparer.cs
+++ /dev/null
@@ -1,41 +0,0 @@
-using MediaBrowser.Controller.Entities;
-using MediaBrowser.Controller.Sorting;
-using MediaBrowser.Model.Querying;
-
-namespace Emby.Server.Implementations.Sorting
-{
- public class MetascoreComparer : IBaseItemComparer
- {
- /// <summary>
- /// Compares the specified x.
- /// </summary>
- /// <param name="x">The x.</param>
- /// <param name="y">The y.</param>
- /// <returns>System.Int32.</returns>
- public int Compare(BaseItem x, BaseItem y)
- {
- return GetValue(x).CompareTo(GetValue(y));
- }
-
- private float GetValue(BaseItem x)
- {
- var hasMetascore = x as IHasMetascore;
-
- if (hasMetascore != null)
- {
- return hasMetascore.Metascore ?? 0;
- }
-
- return 0;
- }
-
- /// <summary>
- /// Gets the name.
- /// </summary>
- /// <value>The name.</value>
- public string Name
- {
- get { return ItemSortBy.Metascore; }
- }
- }
-}