aboutsummaryrefslogtreecommitdiff
path: root/Emby.Server.Implementations
diff options
context:
space:
mode:
authorClaus Vium <cvium@users.noreply.github.com>2020-12-08 18:22:18 +0100
committerJoshua M. Boniface <joshua@boniface.me>2020-12-13 20:34:32 -0500
commitaae90a8480d5ae22913e8e2bcca47a2e55bc3224 (patch)
tree00222f87067bce3fd975e75f031d08e50aab5dad /Emby.Server.Implementations
parent11a37884f01d13d1f5f7a6c8c64299dda4dedf06 (diff)
Merge pull request #4730 from crobibero/base-item-dto-guid-nullable
Don't serialize empty GUID to null (cherry picked from commit b6ecaccf92ae9ca9b0cc75e6dd666a896e72aa99) Signed-off-by: Joshua M. Boniface <joshua@boniface.me>
Diffstat (limited to 'Emby.Server.Implementations')
-rw-r--r--Emby.Server.Implementations/LiveTv/LiveTvManager.cs4
1 files changed, 2 insertions, 2 deletions
diff --git a/Emby.Server.Implementations/LiveTv/LiveTvManager.cs b/Emby.Server.Implementations/LiveTv/LiveTvManager.cs
index 8c9bb6ba0..7842be716 100644
--- a/Emby.Server.Implementations/LiveTv/LiveTvManager.cs
+++ b/Emby.Server.Implementations/LiveTv/LiveTvManager.cs
@@ -1928,7 +1928,7 @@ namespace Emby.Server.Implementations.LiveTv
foreach (var programDto in currentProgramDtos)
{
- if (currentChannelsDict.TryGetValue(programDto.ChannelId, out BaseItemDto channelDto))
+ if (programDto.ChannelId.HasValue && currentChannelsDict.TryGetValue(programDto.ChannelId.Value, out BaseItemDto channelDto))
{
channelDto.CurrentProgram = programDto;
}
@@ -2018,7 +2018,7 @@ namespace Emby.Server.Implementations.LiveTv
info.DayPattern = _tvDtoService.GetDayPattern(info.Days);
info.Name = program.Name;
- info.ChannelId = programDto.ChannelId;
+ info.ChannelId = programDto.ChannelId ?? Guid.Empty;
info.ChannelName = programDto.ChannelName;
info.StartDate = program.StartDate;
info.Name = program.Name;