aboutsummaryrefslogtreecommitdiff
path: root/src/Jellyfin.LiveTv/TunerHosts
diff options
context:
space:
mode:
authorPatrick Barron <barronpm@gmail.com>2024-01-12 18:37:14 -0500
committerPatrick Barron <barronpm@gmail.com>2024-01-12 18:37:14 -0500
commitad51f4f95d09f8ed64fed6013a47f87c01fcca5f (patch)
tree0ab11535887ac831cc93e28418419732ed2b7ccb /src/Jellyfin.LiveTv/TunerHosts
parent93e51353913348a10958eadaa9a2e82cc95cbeaa (diff)
Add LiveTv configuration extension
Diffstat (limited to 'src/Jellyfin.LiveTv/TunerHosts')
-rw-r--r--src/Jellyfin.LiveTv/TunerHosts/BaseTunerHost.cs9
-rw-r--r--src/Jellyfin.LiveTv/TunerHosts/HdHomerun/HdHomerunHost.cs3
2 files changed, 4 insertions, 8 deletions
diff --git a/src/Jellyfin.LiveTv/TunerHosts/BaseTunerHost.cs b/src/Jellyfin.LiveTv/TunerHosts/BaseTunerHost.cs
index 769f196bdf..afc2e4f9ce 100644
--- a/src/Jellyfin.LiveTv/TunerHosts/BaseTunerHost.cs
+++ b/src/Jellyfin.LiveTv/TunerHosts/BaseTunerHost.cs
@@ -10,7 +10,7 @@ using System.Linq;
using System.Text.Json;
using System.Threading;
using System.Threading.Tasks;
-using MediaBrowser.Common.Configuration;
+using Jellyfin.LiveTv.Configuration;
using MediaBrowser.Controller.Configuration;
using MediaBrowser.Controller.Library;
using MediaBrowser.Controller.LiveTv;
@@ -69,7 +69,7 @@ namespace Jellyfin.LiveTv.TunerHosts
protected virtual IList<TunerHostInfo> GetTunerHosts()
{
- return GetConfiguration().TunerHosts
+ return Config.GetLiveTvConfiguration().TunerHosts
.Where(i => string.Equals(i.Type, Type, StringComparison.OrdinalIgnoreCase))
.ToList();
}
@@ -228,10 +228,5 @@ namespace Jellyfin.LiveTv.TunerHosts
return channelId.StartsWith(ChannelIdPrefix, StringComparison.OrdinalIgnoreCase);
}
-
- protected LiveTvOptions GetConfiguration()
- {
- return Config.GetConfiguration<LiveTvOptions>("livetv");
- }
}
}
diff --git a/src/Jellyfin.LiveTv/TunerHosts/HdHomerun/HdHomerunHost.cs b/src/Jellyfin.LiveTv/TunerHosts/HdHomerun/HdHomerunHost.cs
index b1b08e992b..a56af65a6f 100644
--- a/src/Jellyfin.LiveTv/TunerHosts/HdHomerun/HdHomerunHost.cs
+++ b/src/Jellyfin.LiveTv/TunerHosts/HdHomerun/HdHomerunHost.cs
@@ -16,6 +16,7 @@ using System.Threading.Tasks;
using Jellyfin.Extensions;
using Jellyfin.Extensions.Json;
using Jellyfin.Extensions.Json.Converters;
+using Jellyfin.LiveTv.Configuration;
using MediaBrowser.Common.Extensions;
using MediaBrowser.Common.Net;
using MediaBrowser.Controller;
@@ -278,7 +279,7 @@ namespace Jellyfin.LiveTv.TunerHosts.HdHomerun
{
var list = new List<LiveTvTunerInfo>();
- foreach (var host in GetConfiguration().TunerHosts
+ foreach (var host in Config.GetLiveTvConfiguration().TunerHosts
.Where(i => string.Equals(i.Type, Type, StringComparison.OrdinalIgnoreCase)))
{
try