aboutsummaryrefslogtreecommitdiff
path: root/MediaBrowser.Controller
diff options
context:
space:
mode:
authorLuke <luke.pulverenti@gmail.com>2016-12-08 01:54:16 -0500
committerGitHub <noreply@github.com>2016-12-08 01:54:16 -0500
commit862018b5c20e27dc67619b8c0c212507685e8120 (patch)
tree3afc3ec162582d6dfd5a9b6feb60caefca6d5f2d /MediaBrowser.Controller
parentfa6b90eb745c2491ae50ce4fe1e2fb5700f87399 (diff)
parent9ed3c311757a615ae32296da4b43f772370d1143 (diff)
Merge pull request #2333 from MediaBrowser/dev
Dev
Diffstat (limited to 'MediaBrowser.Controller')
-rw-r--r--MediaBrowser.Controller/Entities/TV/Episode.cs12
1 files changed, 11 insertions, 1 deletions
diff --git a/MediaBrowser.Controller/Entities/TV/Episode.cs b/MediaBrowser.Controller/Entities/TV/Episode.cs
index 2bcccf5e8b..737257898d 100644
--- a/MediaBrowser.Controller/Entities/TV/Episode.cs
+++ b/MediaBrowser.Controller/Entities/TV/Episode.cs
@@ -3,6 +3,7 @@ using MediaBrowser.Model.Configuration;
using MediaBrowser.Model.Entities;
using System;
using System.Collections.Generic;
+using System.Globalization;
using System.Linq;
using MediaBrowser.Model.Serialization;
@@ -184,7 +185,16 @@ namespace MediaBrowser.Controller.Entities.TV
public string FindSeasonName()
{
- var season = Season;
+ var season = Season;
+
+ if (season == null)
+ {
+ if (ParentIndexNumber.HasValue)
+ {
+ return "Season " + ParentIndexNumber.Value.ToString(CultureInfo.InvariantCulture);
+ }
+ }
+
return season == null ? SeasonName : season.Name;
}