File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -32,7 +32,7 @@ public static class Settings
3232 /// The first matching parser "wins" for auto discovery and presets when multiple
3333 /// files of the same base name, but different supported extensions, exist.
3434 /// </summary>
35- private static readonly List < ISettingsParser > s_parsers = new ( )
35+ private static readonly ISettingsParser [ ] s_parsers =
3636 {
3737 new JsonSettingsParser ( ) ,
3838 new Psd1SettingsParser ( )
@@ -281,7 +281,7 @@ private static string ResolveProviderPathIfPossible(
281281 /// <exception cref="NotSupportedException">If no parser can handle the file.</exception>
282282 private static SettingsData ParseFile ( string path )
283283 {
284- var parser = s_parsers . Find ( p => p . CanParse ( path ) ) ??
284+ var parser = Array . Find ( s_parsers , p => p . CanParse ( path ) ) ??
285285 throw new NotSupportedException ( $ "No parser registered for settings file '{ path } '.") ;
286286 using var fs = File . OpenRead ( path ) ;
287287 var data = parser . Parse ( fs , path ) ;
You can’t perform that action at this time.
0 commit comments