From 785815ffc81cc95f97472f83e8024d773d3cd554 Mon Sep 17 00:00:00 2001 From: Marco Gavelli Date: Fri, 1 Apr 2022 19:14:49 +0200 Subject: [PATCH] Case insensitive extension comparison --- src/Files.Uwp/ViewModels/Previews/CodePreviewViewModel.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Files.Uwp/ViewModels/Previews/CodePreviewViewModel.cs b/src/Files.Uwp/ViewModels/Previews/CodePreviewViewModel.cs index aea418eb5194..c110605001b9 100644 --- a/src/Files.Uwp/ViewModels/Previews/CodePreviewViewModel.cs +++ b/src/Files.Uwp/ViewModels/Previews/CodePreviewViewModel.cs @@ -79,6 +79,6 @@ public async override Task> LoadPreviewAndDetails() {Languages.Aspx, new List {".aspx"} }, }; - private static ILanguage GetCodeLanguage(string ext) => languageExtensions.FirstOrDefault(x => x.Value.Contains(ext)).Key; + private static ILanguage GetCodeLanguage(string ext) => languageExtensions.FirstOrDefault(x => x.Value.Contains(ext, StringComparer.OrdinalIgnoreCase)).Key; } } \ No newline at end of file