From 38d88aed5811d22feef83e05753d95624efe0ded Mon Sep 17 00:00:00 2001 From: Luke Pulverenti Date: Thu, 6 Feb 2014 10:58:49 -0500 Subject: Inherit custom rating --- MediaBrowser.Controller/Entities/BaseItem.cs | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) (limited to 'MediaBrowser.Controller/Entities/BaseItem.cs') diff --git a/MediaBrowser.Controller/Entities/BaseItem.cs b/MediaBrowser.Controller/Entities/BaseItem.cs index de5516e299..c21b9b05f3 100644 --- a/MediaBrowser.Controller/Entities/BaseItem.cs +++ b/MediaBrowser.Controller/Entities/BaseItem.cs @@ -447,9 +447,23 @@ namespace MediaBrowser.Controller.Entities } [IgnoreDataMember] - public virtual string CustomRatingForComparison + public string CustomRatingForComparison { - get { return CustomRating; } + get + { + if (!string.IsNullOrEmpty(CustomRating)) + { + return CustomRating; + } + + var parent = Parent; + if (parent != null) + { + return parent.CustomRatingForComparison; + } + + return null; + } } /// -- cgit v1.2.3