The Free Software Media System - Server Backend & API
Remove precondition checks
crobibero7bf647bb942f
diff --git a/Jellyfin.Api/Controllers/ItemsController.cs b/Jellyfin.Api/Controllers/ItemsController.csindex 43282b6851..6d30a3d425 100644--- a/Jellyfin.Api/Controllers/ItemsController.cs+++ b/Jellyfin.Api/Controllers/ItemsController.cs@@ -412,13 +412,9 @@ namespace Jellyfin.Api.Controllersquery.IsVirtualItem = false;}- if (locationTypes.Length != 0)+ if (locationTypes.Length > 0 && locationTypes.Length < 4){- var requestedLocationTypes = locationTypes;- if (requestedLocationTypes.Length > 0 && requestedLocationTypes.Length < 4)- {- query.IsVirtualItem = requestedLocationTypes.Contains(LocationType.Virtual);- }+ query.IsVirtualItem = locationTypes.Contains(LocationType.Virtual);}// Min official rating