diff options
| author | Bond-009 <bond.009@outlook.com> | 2026-05-06 17:40:12 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2026-05-06 17:40:12 +0200 |
| commit | e50aeb914acdd1fcb5e48f9260459811bcb343b9 (patch) | |
| tree | 8dcfde11a7ba79253bc38cf0ee5468a6ab87bffd | |
| parent | 087e745e7a36cb1e98d0c07018c6026a30062d29 (diff) | |
| parent | 8271568677f886c865152d9818c7f2b012e943a7 (diff) | |
Merge pull request #16322 from poytiis/remove-ToList-calls
Remove unnecessary ToList calls in TrickplayManager
| -rw-r--r-- | CONTRIBUTORS.md | 1 | ||||
| -rw-r--r-- | Jellyfin.Server.Implementations/Trickplay/TrickplayManager.cs | 4 |
2 files changed, 3 insertions, 2 deletions
diff --git a/CONTRIBUTORS.md b/CONTRIBUTORS.md index c42962786d..e5478a7ba6 100644 --- a/CONTRIBUTORS.md +++ b/CONTRIBUTORS.md @@ -118,6 +118,7 @@ - [Phlogi](https://github.com/Phlogi) - [pjeanjean](https://github.com/pjeanjean) - [ploughpuff](https://github.com/ploughpuff) + - [poytiis](https://github.com/poytiis) - [pR0Ps](https://github.com/pR0Ps) - [PrplHaz4](https://github.com/PrplHaz4) - [RazeLighter777](https://github.com/RazeLighter777) diff --git a/Jellyfin.Server.Implementations/Trickplay/TrickplayManager.cs b/Jellyfin.Server.Implementations/Trickplay/TrickplayManager.cs index 63319831e1..0791e04e85 100644 --- a/Jellyfin.Server.Implementations/Trickplay/TrickplayManager.cs +++ b/Jellyfin.Server.Implementations/Trickplay/TrickplayManager.cs @@ -198,13 +198,13 @@ public class TrickplayManager : ITrickplayManager // Cleanup old trickplay files if (Directory.Exists(trickplayDirectory)) { - var existingFolders = Directory.GetDirectories(trickplayDirectory).ToList(); + var existingFolders = Directory.GetDirectories(trickplayDirectory); var trickplayInfos = await dbContext.TrickplayInfos .AsNoTracking() .Where(i => i.ItemId.Equals(video.Id)) .ToListAsync(cancellationToken) .ConfigureAwait(false); - var expectedFolders = trickplayInfos.Select(i => GetTrickplayDirectory(video, i.TileWidth, i.TileHeight, i.Width, saveWithMedia)).ToList(); + var expectedFolders = trickplayInfos.Select(i => GetTrickplayDirectory(video, i.TileWidth, i.TileHeight, i.Width, saveWithMedia)); var foldersToRemove = existingFolders.Except(expectedFolders); foreach (var folder in foldersToRemove) { |
