finish removing ChannelFolderItem

This commit is contained in:
Luke Pulverenti
2016-03-19 01:04:38 -04:00
parent cbac67b5ae
commit 7b93b7a33c
17 changed files with 184 additions and 105 deletions

View File

@@ -1534,9 +1534,13 @@ namespace MediaBrowser.Server.Implementations.Dto
dto.ChannelId = item.ChannelId;
if (item.SourceType == SourceType.Channel)
if (item.SourceType == SourceType.Channel && !string.IsNullOrWhiteSpace(item.ChannelId))
{
dto.ChannelName = _channelManagerFactory().GetChannel(item.ChannelId).Name;
var channel = _libraryManager.GetItemById(item.ChannelId);
if (channel != null)
{
dto.ChannelName = channel.Name;
}
}
}