mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-06-03 06:18:28 +01:00
Remove conditions that are always true/false
This commit is contained in:
@@ -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;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user