Add tag filtering and random sorting to GetSimilarItems (#14918)

This commit is contained in:
theguymadmax 2025-10-01 19:26:48 -04:00 committed by GitHub
parent c053a6cd78
commit d6cebf1e67
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 4 additions and 2 deletions

View file

@ -779,12 +779,14 @@ public class LibraryController : BaseJellyfinApiController
var query = new InternalItemsQuery(user)
{
Genres = item.Genres,
Tags = item.Tags,
Limit = limit,
IncludeItemTypes = includeItemTypes.ToArray(),
DtoOptions = dtoOptions,
EnableTotalRecordCount = !isMovie ?? true,
EnableGroupByMetadataKey = isMovie ?? false,
ExcludeItemIds = [itemId]
ExcludeItemIds = [itemId],
OrderBy = [(ItemSortBy.Random, SortOrder.Ascending)]
};
// ExcludeArtistIds