From 9c6b4f033ab92dcc042d1a6a7016d8b9a2005bf5 Mon Sep 17 00:00:00 2001 From: crobibero Date: Mon, 17 Aug 2020 14:55:14 -0600 Subject: [PATCH] revert lastordefault --- Jellyfin.Api/Controllers/ItemLookupController.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jellyfin.Api/Controllers/ItemLookupController.cs b/Jellyfin.Api/Controllers/ItemLookupController.cs index a752af545..2857d6c8d 100644 --- a/Jellyfin.Api/Controllers/ItemLookupController.cs +++ b/Jellyfin.Api/Controllers/ItemLookupController.cs @@ -332,7 +332,7 @@ namespace Jellyfin.Api.Controllers private async Task DownloadImage(string providerName, string url, Guid urlHash, string pointerCachePath) { using var result = await _providerManager.GetSearchImage(providerName, url, CancellationToken.None).ConfigureAwait(false); - var ext = result.Content.Headers.ContentType.MediaType.Split('/').LastOrDefault(); + var ext = result.Content.Headers.ContentType.MediaType.Split('/').Last(); var fullCachePath = GetFullCachePath(urlHash + "." + ext); Directory.CreateDirectory(Path.GetDirectoryName(fullCachePath));