aboutsummaryrefslogtreecommitdiff
path: root/MediaBrowser.Controller
diff options
context:
space:
mode:
authorLuke Pulverenti <luke.pulverenti@gmail.com>2016-12-07 15:03:00 -0500
committerLuke Pulverenti <luke.pulverenti@gmail.com>2016-12-07 15:03:00 -0500
commit63a69cdc60361b2031e4090b55e45bdb9ca73c94 (patch)
treed852e5534a8e609eb72c889a4ee25071db821023 /MediaBrowser.Controller
parent0130209cdce07dc042b075c6cf972a7eb1339861 (diff)
improve m3u channel list parsing
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;
}