mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-10-21 16:22:15 +00:00
Reduce string allocations
Some simple changes to reduce the number of allocated strings
This commit is contained in:
parent
40f7eb4e8c
commit
b176beb88e
21 changed files with 63 additions and 97 deletions
|
|
@ -222,7 +222,7 @@ namespace Emby.Server.Implementations.MediaEncoder
|
|||
{
|
||||
var deadImages = images
|
||||
.Except(chapters.Select(i => i.ImagePath).Where(i => !string.IsNullOrEmpty(i)), StringComparer.OrdinalIgnoreCase)
|
||||
.Where(i => BaseItem.SupportedImageExtensions.Contains(Path.GetExtension(i), StringComparison.OrdinalIgnoreCase))
|
||||
.Where(i => BaseItem.SupportedImageExtensions.Contains(Path.GetExtension(i.AsSpan()), StringComparison.OrdinalIgnoreCase))
|
||||
.ToList();
|
||||
|
||||
foreach (var image in deadImages)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue