aboutsummaryrefslogtreecommitdiff
path: root/Jellyfin.Api/Controllers/LibraryStructureController.cs
diff options
context:
space:
mode:
authorBond-009 <bond.009@outlook.com>2024-04-30 21:32:59 +0200
committerGitHub <noreply@github.com>2024-04-30 13:32:59 -0600
commit3feb3f81bfe848aa829e7c129bee3cd060c23c05 (patch)
treec247db8e30d1cc52bc6735d45d86eff8955ee7e9 /Jellyfin.Api/Controllers/LibraryStructureController.cs
parent5dc6bb4910cfdc7f40ad83d647172d743e6e0595 (diff)
More efficient array creation (#11468)
Diffstat (limited to 'Jellyfin.Api/Controllers/LibraryStructureController.cs')
-rw-r--r--Jellyfin.Api/Controllers/LibraryStructureController.cs2
1 files changed, 1 insertions, 1 deletions
diff --git a/Jellyfin.Api/Controllers/LibraryStructureController.cs b/Jellyfin.Api/Controllers/LibraryStructureController.cs
index f685eeaa0..fb9f44d46 100644
--- a/Jellyfin.Api/Controllers/LibraryStructureController.cs
+++ b/Jellyfin.Api/Controllers/LibraryStructureController.cs
@@ -85,7 +85,7 @@ public class LibraryStructureController : BaseJellyfinApiController
if (paths is not null && paths.Length > 0)
{
- libraryOptions.PathInfos = paths.Select(i => new MediaPathInfo(i)).ToArray();
+ libraryOptions.PathInfos = Array.ConvertAll(paths, i => new MediaPathInfo(i));
}
await _libraryManager.AddVirtualFolder(name, collectionType, libraryOptions, refreshLibrary).ConfigureAwait(false);