Apply suggestions from code review

Co-authored-by: Cody Robibero <cody@robibe.ro>
This commit is contained in:
JPVenson
2024-10-09 21:03:57 +02:00
committed by GitHub
parent 5267851e64
commit 473628ba3a
7 changed files with 7 additions and 11 deletions

View File

@@ -37,7 +37,7 @@ public class MediaStreamRepository(IDbContextFactory<JellyfinDbContext> dbProvid
public IReadOnlyList<MediaStream> GetMediaStreams(MediaStreamQuery filter)
{
using var context = dbProvider.CreateDbContext();
return TranslateQuery(context.MediaStreamInfos, filter).ToList().Select(Map).ToImmutableArray();
return TranslateQuery(context.MediaStreamInfos, filter).AsEnumerable().Select(Map).ToImmutableArray();
}
private string? GetPathToSave(string? path)