Merge pull request #1753 from aspnet/release/2.1
Fix WebSocketsSupportedConditionAttribute version check (#1751)
This commit is contained in:
commit
dcb8862090
|
|
@ -20,19 +20,14 @@ namespace Microsoft.AspNetCore.SignalR.Tests
|
|||
// .NET Core 2.1 and greater has sockets
|
||||
return true;
|
||||
#else
|
||||
// Non-Windows platforms have sockets
|
||||
// Non-Windows platforms have Websockets
|
||||
if (!RuntimeInformation.IsOSPlatform(OSPlatform.Windows))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
// Windows 8 and greater has sockets
|
||||
if (Environment.Version >= new Version(6, 2))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
// Windows 8 and greater has Websockets
|
||||
return Environment.OSVersion.Version >= new Version(6, 2);
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue