diff options
| author | Shadowghost <Ghost_of_Stone@web.de> | 2026-06-01 20:05:09 +0200 |
|---|---|---|
| committer | Shadowghost <Ghost_of_Stone@web.de> | 2026-06-01 21:54:49 +0200 |
| commit | cc5fb3f1eec11fcb4af5fbbc93b4d78b0568e2b4 (patch) | |
| tree | 8519a660dd5b77b9e1fc9269aadec09e4079fa18 | |
| parent | 54463929d0d63ec42a1246565ddbe896a1393e55 (diff) | |
Only default recursive to true if we have includeItemTypes
| -rw-r--r-- | Jellyfin.Api/Controllers/ItemsController.cs | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/Jellyfin.Api/Controllers/ItemsController.cs b/Jellyfin.Api/Controllers/ItemsController.cs index 363af9e43b..5705284cfb 100644 --- a/Jellyfin.Api/Controllers/ItemsController.cs +++ b/Jellyfin.Api/Controllers/ItemsController.cs @@ -318,9 +318,6 @@ public class ItemsController : BaseJellyfinApiController } else if (folder is ICollectionFolder) { - // When the client doesn't specify recursive/includeItemTypes, force the query - // through the database path where all filters (IsHD, genres, etc.) are applied. - recursive ??= true; if (includeItemTypes.Length == 0) { includeItemTypes = collectionType switch @@ -330,6 +327,13 @@ public class ItemsController : BaseJellyfinApiController _ => [] }; } + + // When the client doesn't specify recursive/includeItemTypes, force the query + // through the database path where all filters (IsHD, genres, etc.) are applied. + if (includeItemTypes.Length > 0) + { + recursive ??= true; + } } if (item is not UserRootFolder |
