aboutsummaryrefslogtreecommitdiff
path: root/MediaBrowser.Server.Implementations/Sorting/RevenueComparer.cs
diff options
context:
space:
mode:
Diffstat (limited to 'MediaBrowser.Server.Implementations/Sorting/RevenueComparer.cs')
-rw-r--r--MediaBrowser.Server.Implementations/Sorting/RevenueComparer.cs7
1 files changed, 6 insertions, 1 deletions
diff --git a/MediaBrowser.Server.Implementations/Sorting/RevenueComparer.cs b/MediaBrowser.Server.Implementations/Sorting/RevenueComparer.cs
index e9d7912a1..6caa27ac3 100644
--- a/MediaBrowser.Server.Implementations/Sorting/RevenueComparer.cs
+++ b/MediaBrowser.Server.Implementations/Sorting/RevenueComparer.cs
@@ -19,7 +19,12 @@ namespace MediaBrowser.Server.Implementations.Sorting
private double GetValue(BaseItem x)
{
- return x.Revenue ?? 0;
+ var hasBudget = x as IHasBudget;
+ if (hasBudget != null)
+ {
+ return hasBudget.Revenue ?? 0;
+ }
+ return 0;
}
/// <summary>