aboutsummaryrefslogtreecommitdiff
path: root/MediaBrowser.Server.Implementations/LiveTv/LiveTvManager.cs
diff options
context:
space:
mode:
Diffstat (limited to 'MediaBrowser.Server.Implementations/LiveTv/LiveTvManager.cs')
-rw-r--r--MediaBrowser.Server.Implementations/LiveTv/LiveTvManager.cs29
1 files changed, 29 insertions, 0 deletions
diff --git a/MediaBrowser.Server.Implementations/LiveTv/LiveTvManager.cs b/MediaBrowser.Server.Implementations/LiveTv/LiveTvManager.cs
index cabe04f0f..4109617db 100644
--- a/MediaBrowser.Server.Implementations/LiveTv/LiveTvManager.cs
+++ b/MediaBrowser.Server.Implementations/LiveTv/LiveTvManager.cs
@@ -2286,5 +2286,34 @@ namespace MediaBrowser.Server.Implementations.LiveTv
return provider.GetLineups(info, country, location);
}
}
+
+ public Task<MBRegistrationRecord> GetRegistrationInfo(string channelId, string programId, string feature)
+ {
+ ILiveTvService service;
+
+ if (string.IsNullOrWhiteSpace(programId))
+ {
+ var channel = GetInternalChannel(channelId);
+ service = GetService(channel);
+ }
+ else
+ {
+ var program = GetInternalProgram(programId);
+ service = GetService(program);
+ }
+
+ var hasRegistration = service as IHasRegistrationInfo;
+
+ if (hasRegistration != null)
+ {
+ return hasRegistration.GetRegistrationInfo(feature);
+ }
+
+ return Task.FromResult(new MBRegistrationRecord
+ {
+ IsValid = true,
+ IsRegistered = true
+ });
+ }
}
}