From ffcbc246cff28d35996c44054afe6e81461d69fa Mon Sep 17 00:00:00 2001 From: David McFarland Date: Wed, 30 Dec 2020 23:36:32 -0400 Subject: [PATCH] fix exception with null sdk version This happens when the dotnet sdk isn't available in PATH. --- src/OmniSharp.MSBuild/ProjectLoadListener.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/OmniSharp.MSBuild/ProjectLoadListener.cs b/src/OmniSharp.MSBuild/ProjectLoadListener.cs index 1d25dc32b1..9bf8630680 100644 --- a/src/OmniSharp.MSBuild/ProjectLoadListener.cs +++ b/src/OmniSharp.MSBuild/ProjectLoadListener.cs @@ -87,7 +87,7 @@ private static HashedString GetProjectId(ProjectLoadedEventArgs args) private static HashedString GetSdkVersion(ProjectLoadedEventArgs args) { - return _tfmAndFileHashingAlgorithm.HashInput(args.SdkVersion.ToString()); + return _tfmAndFileHashingAlgorithm.HashInput($"{args.SdkVersion}"); } private static HashedString GetSessionId(ProjectLoadedEventArgs args)