diff options
| author | Bond_009 <bond.009@outlook.com> | 2019-01-21 20:18:52 +0100 |
|---|---|---|
| committer | Bond_009 <bond.009@outlook.com> | 2019-01-22 23:49:51 +0100 |
| commit | 722120af74fadc1dfb43f1535797464a0ba63ba9 (patch) | |
| tree | eb3853accbefd0be6a46ece93876cfa0ebe33784 /Emby.Server.Implementations/Channels/ChannelManager.cs | |
| parent | edcfd8b565f632088c8b1f826db8e2fbecf9790d (diff) | |
Remove conditions that are always true/false
Diffstat (limited to 'Emby.Server.Implementations/Channels/ChannelManager.cs')
| -rw-r--r-- | Emby.Server.Implementations/Channels/ChannelManager.cs | 15 |
1 files changed, 5 insertions, 10 deletions
diff --git a/Emby.Server.Implementations/Channels/ChannelManager.cs b/Emby.Server.Implementations/Channels/ChannelManager.cs index 660547c85..a306b0169 100644 --- a/Emby.Server.Implementations/Channels/ChannelManager.cs +++ b/Emby.Server.Implementations/Channels/ChannelManager.cs @@ -681,22 +681,17 @@ namespace Emby.Server.Implementations.Channels // Find the corresponding channel provider plugin var channelProvider = GetChannelProvider(channel); - var user = query.User; - - ChannelItemSortField? sortField = null; - var sortDescending = false; - - var parentItem = !query.ParentId.Equals(Guid.Empty) ? _libraryManager.GetItemById(query.ParentId) : channel; + var parentItem = query.ParentId == Guid.Empty ? channel : _libraryManager.GetItemById(query.ParentId); var itemsResult = await GetChannelItems(channelProvider, - user, + query.User, parentItem is Channel ? null : parentItem.ExternalId, - sortField, - sortDescending, + null, + false, cancellationToken) .ConfigureAwait(false); - if (query.ParentId.Equals(Guid.Empty)) + if (query.ParentId == Guid.Empty) { query.Parent = channel; } |
