From 43407c5438c08adee07bf675a95b4b3f36f8bc7c Mon Sep 17 00:00:00 2001 From: Steve Bjorg Date: Tue, 6 Oct 2020 13:19:29 -0700 Subject: [PATCH] fix Blazor WASM check --- src/GraphQL.Client/Websocket/GraphQLHttpWebSocket.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/GraphQL.Client/Websocket/GraphQLHttpWebSocket.cs b/src/GraphQL.Client/Websocket/GraphQLHttpWebSocket.cs index aba35e8f..d8476b72 100644 --- a/src/GraphQL.Client/Websocket/GraphQLHttpWebSocket.cs +++ b/src/GraphQL.Client/Websocket/GraphQLHttpWebSocket.cs @@ -408,7 +408,7 @@ public Task InitializeWebSocket() #else _clientWebSocket = new ClientWebSocket(); _clientWebSocket.Options.AddSubProtocol("graphql-ws"); - if(!System.Runtime.InteropServices.RuntimeInformation.IsOSPlatform(System.Runtime.InteropServices.OSPlatform.Create("WEBASSEMBLY"))) + if(!System.Runtime.InteropServices.RuntimeInformation.IsOSPlatform(System.Runtime.InteropServices.OSPlatform.Create("BROWSER"))) { // the following properties are not supported in Blazor WebAssembly and throw a PlatformNotSupportedException error when accessed _clientWebSocket.Options.ClientCertificates = ((HttpClientHandler)Options.HttpMessageHandler).ClientCertificates;