aboutsummaryrefslogtreecommitdiff
path: root/Jellyfin.Api/Controllers/ItemsController.cs
diff options
context:
space:
mode:
authorPrplHaz4 <PrplHaz4@users.noreply.github.com>2020-08-27 10:12:32 -0400
committerGitHub <noreply@github.com>2020-08-27 10:12:32 -0400
commit34219e2831a01d5e056c0cfd2b6d755f3be4b416 (patch)
treebf19d717cb466de9ee9fa67b01a6301641a2b647 /Jellyfin.Api/Controllers/ItemsController.cs
parentba7bdbc4945157025cc754b736d1135b5695a979 (diff)
Fix permissions for individual channel plugins #2858
Without this change, the only Channel (plugin, not Live TV) permission that works is "Enable All Channels". Fixes #2858
Diffstat (limited to 'Jellyfin.Api/Controllers/ItemsController.cs')
-rw-r--r--Jellyfin.Api/Controllers/ItemsController.cs4
1 files changed, 3 insertions, 1 deletions
diff --git a/Jellyfin.Api/Controllers/ItemsController.cs b/Jellyfin.Api/Controllers/ItemsController.cs
index 1b8b68313..6b0eb8f24 100644
--- a/Jellyfin.Api/Controllers/ItemsController.cs
+++ b/Jellyfin.Api/Controllers/ItemsController.cs
@@ -266,7 +266,9 @@ namespace Jellyfin.Api.Controllers
bool isInEnabledFolder = user!.GetPreference(PreferenceKind.EnabledFolders).Any(i => new Guid(i) == item.Id)
// Assume all folders inside an EnabledChannel are enabled
- || user.GetPreference(PreferenceKind.EnabledChannels).Any(i => new Guid(i) == item.Id);
+ || user.GetPreference(PreferenceKind.EnabledChannels).Any(i => new Guid(i) == item.Id)
+ // Assume all items inside an EnabledChannel are enabled
+ || user.GetPreference(PreferenceKind.EnabledChannels).Any(i => new Guid(i) == item.ChannelId);
var collectionFolders = _libraryManager.GetCollectionFolders(item);
foreach (var collectionFolder in collectionFolders)