Fix #if for full framework SignalR client (#27999)
This commit is contained in:
parent
20e2c6fcae
commit
af907cdea5
|
|
@ -44,7 +44,7 @@ namespace Microsoft.AspNetCore.Http.Connections.Client.Internal
|
||||||
{
|
{
|
||||||
// Full Framework will throw when trying to set the User-Agent header
|
// Full Framework will throw when trying to set the User-Agent header
|
||||||
// So avoid setting it in netstandard2.0 and only set it in netstandard2.1 and higher
|
// So avoid setting it in netstandard2.0 and only set it in netstandard2.1 and higher
|
||||||
#if !NETSTANDARD2_0
|
#if !NETSTANDARD2_0 && !NET461
|
||||||
_webSocket.Options.SetRequestHeader("User-Agent", Constants.UserAgentHeader.ToString());
|
_webSocket.Options.SetRequestHeader("User-Agent", Constants.UserAgentHeader.ToString());
|
||||||
#else
|
#else
|
||||||
// Set an alternative user agent header on Full framework
|
// Set an alternative user agent header on Full framework
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue