From 968df6ccd98b49c35e78cf7fcee5d8491b7c4387 Mon Sep 17 00:00:00 2001 From: sbansla Date: Mon, 11 Mar 2024 18:06:01 +0530 Subject: [PATCH] adding support for net35 net462 and netstandard2.1 --- src/Twilio/Http/SystemNetHttpClient.cs | 6 ++-- src/Twilio/Twilio.csproj | 38 ++++++++++++++++++++++---- 2 files changed, 35 insertions(+), 9 deletions(-) diff --git a/src/Twilio/Http/SystemNetHttpClient.cs b/src/Twilio/Http/SystemNetHttpClient.cs index 29762072f..117466f2d 100644 --- a/src/Twilio/Http/SystemNetHttpClient.cs +++ b/src/Twilio/Http/SystemNetHttpClient.cs @@ -15,8 +15,8 @@ namespace Twilio.Http /// public class SystemNetHttpClient : HttpClient { -#if NET451 - private string PlatVersion = ".NET Framework 4.5.1+"; +#if NET462 + private string PlatVersion = ".NET Framework 4.6.2+"; #else private string PlatVersion = RuntimeInformation.FrameworkDescription; #endif @@ -125,7 +125,7 @@ private HttpRequestMessage BuildHttpRequest(Request request) #endif string osArch; -#if !NET451 +#if !NET462 osArch = RuntimeInformation.OSArchitecture.ToString(); #else osArch = Environment.GetEnvironmentVariable("PROCESSOR_ARCHITECTURE") ?? "Unknown"; diff --git a/src/Twilio/Twilio.csproj b/src/Twilio/Twilio.csproj index 10dd28869..9f03494a6 100644 --- a/src/Twilio/Twilio.csproj +++ b/src/Twilio/Twilio.csproj @@ -1,8 +1,6 @@  - net6.0 - bin/Release - enable + net6.0;netstandard2.1;net462;net35 true Twilio Twilio REST API helper library @@ -24,12 +22,40 @@ http://github.com/twilio/twilio-csharp git True + 2.1.0 - + + + + + + + + + + - - + + + + + + + + + + + + + + + + + + + + \ No newline at end of file