aboutsummaryrefslogtreecommitdiff
path: root/Jellyfin.Api/Controllers/ItemsController.cs
diff options
context:
space:
mode:
authorShadowghost <Ghost_of_Stone@web.de>2022-11-28 13:07:57 +0100
committerShadowghost <Ghost_of_Stone@web.de>2023-02-20 11:53:20 +0100
commit2e315b7f085ca0b9a2f61a7ac71a46ca84750f9f (patch)
treeac2f385eebf63d1efb38ad965b0f73499889e715 /Jellyfin.Api/Controllers/ItemsController.cs
parenta6cfe75d6e422eb1343a1f4bc2410fabb425266b (diff)
Properly build where clause for rating checks
Diffstat (limited to 'Jellyfin.Api/Controllers/ItemsController.cs')
-rw-r--r--Jellyfin.Api/Controllers/ItemsController.cs7
1 files changed, 7 insertions, 0 deletions
diff --git a/Jellyfin.Api/Controllers/ItemsController.cs b/Jellyfin.Api/Controllers/ItemsController.cs
index 728e62810..377526729 100644
--- a/Jellyfin.Api/Controllers/ItemsController.cs
+++ b/Jellyfin.Api/Controllers/ItemsController.cs
@@ -411,6 +411,13 @@ public class ItemsController : BaseJellyfinApiController
query.SeriesStatuses = seriesStatus;
}
+ // Exclude Blocked Unrated Items
+ var blockedUnratedItems = user?.GetPreferenceValues<UnratedItem>(PreferenceKind.BlockUnratedItems);
+ if (blockedUnratedItems is not null)
+ {
+ query.BlockUnratedItems = blockedUnratedItems;
+ }
+
// ExcludeLocationTypes
if (excludeLocationTypes.Any(t => t == LocationType.Virtual))
{