From 00a608dfabfe50b26adccef6ea87e46066a188f6 Mon Sep 17 00:00:00 2001 From: Bond-009 Date: Tue, 15 Dec 2020 12:22:39 +0100 Subject: Merge pull request #4781 from crobibero/map-xmltv Use request body for mapping xml channels (cherry picked from commit 906ee4f96229a0cc4c481911d6443c68af6d4a2d) Signed-off-by: Joshua M. Boniface --- Jellyfin.Api/Controllers/LiveTvController.cs | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) (limited to 'Jellyfin.Api/Controllers/LiveTvController.cs') diff --git a/Jellyfin.Api/Controllers/LiveTvController.cs b/Jellyfin.Api/Controllers/LiveTvController.cs index 56d4b3933..6f2d43227 100644 --- a/Jellyfin.Api/Controllers/LiveTvController.cs +++ b/Jellyfin.Api/Controllers/LiveTvController.cs @@ -1119,20 +1119,15 @@ namespace Jellyfin.Api.Controllers /// /// Set channel mappings. /// - /// Provider id. - /// Tuner channel id. - /// Provider channel id. + /// The set channel mapping dto. /// Created channel mapping returned. /// An containing the created channel mapping. [HttpPost("ChannelMappings")] [Authorize(Policy = Policies.DefaultAuthorization)] [ProducesResponseType(StatusCodes.Status200OK)] - public async Task> SetChannelMapping( - [FromQuery] string? providerId, - [FromQuery] string? tunerChannelId, - [FromQuery] string? providerChannelId) + public async Task> SetChannelMapping([FromBody, Required] SetChannelMappingDto setChannelMappingDto) { - return await _liveTvManager.SetChannelMapping(providerId, tunerChannelId, providerChannelId).ConfigureAwait(false); + return await _liveTvManager.SetChannelMapping(setChannelMappingDto.ProviderId, setChannelMappingDto.TunerChannelId, setChannelMappingDto.ProviderChannelId).ConfigureAwait(false); } /// -- cgit v1.2.3