From 738e96fa9270deb7dad5e38c35cffa949d089bcf Mon Sep 17 00:00:00 2001 From: Bradley Grainger Date: Wed, 10 Jul 2024 20:35:19 -0700 Subject: [PATCH] Fix IDE0300 'Collection initialization can be simplified'. --- src/Faithlife.Build/MSBuildRunner.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/Faithlife.Build/MSBuildRunner.cs b/src/Faithlife.Build/MSBuildRunner.cs index 66317ff..b5339ad 100644 --- a/src/Faithlife.Build/MSBuildRunner.cs +++ b/src/Faithlife.Build/MSBuildRunner.cs @@ -51,9 +51,9 @@ public static string GetMSBuildPath(MSBuildSettings? settings) { return version switch { - MSBuildVersion.VS2017 => (new[] { Environment.SpecialFolder.ProgramFilesX86 }, "2017", "15.0"), - MSBuildVersion.VS2019 => (new[] { Environment.SpecialFolder.ProgramFilesX86 }, "2019", "Current"), - MSBuildVersion.VS2022 => (new[] { Environment.SpecialFolder.ProgramFiles, Environment.SpecialFolder.ProgramFilesX86 }, "2022", "Current"), + MSBuildVersion.VS2017 => ([Environment.SpecialFolder.ProgramFilesX86], "2017", "15.0"), + MSBuildVersion.VS2019 => ([Environment.SpecialFolder.ProgramFilesX86], "2019", "Current"), + MSBuildVersion.VS2022 => ([Environment.SpecialFolder.ProgramFiles, Environment.SpecialFolder.ProgramFilesX86], "2022", "Current"), _ => throw new BuildException($"Unexpected MSBuildVersion: {version}"), }; }