diff --git a/src/Pose/Extensions/DictionaryExtensions.cs b/src/Pose/Extensions/DictionaryExtensions.cs index 59f4756..9d973dc 100644 --- a/src/Pose/Extensions/DictionaryExtensions.cs +++ b/src/Pose/Extensions/DictionaryExtensions.cs @@ -6,6 +6,7 @@ internal static class DictionaryExtensions { public static bool TryAdd(this Dictionary dictionary, TKey key, TValue value) { +#if NETSTANDARD2_0 || NET48 try { dictionary.Add(key, value); @@ -15,6 +16,9 @@ public static bool TryAdd(this Dictionary dictionary { return false; } +#else + return dictionary.TryAdd(key, value); +#endif } } } \ No newline at end of file diff --git a/src/Pose/Pose.csproj b/src/Pose/Pose.csproj index c6085dd..fda9cc8 100644 --- a/src/Pose/Pose.csproj +++ b/src/Pose/Pose.csproj @@ -3,7 +3,7 @@ Pose Replace any .NET method (including static and non-virtual) with a delegate 1.2.1 - netstandard2.0;netstandard2.1 + netstandard2.0;netcoreapp3.0;net48 portable Pose Pose diff --git a/test/Pose.Tests/Pose.Tests.csproj b/test/Pose.Tests/Pose.Tests.csproj index 66b8c41..9877c69 100644 --- a/test/Pose.Tests/Pose.Tests.csproj +++ b/test/Pose.Tests/Pose.Tests.csproj @@ -1,7 +1,7 @@ - netcoreapp2.0;netcoreapp3.0;netcoreapp2.1;netcoreapp3.1;net48 + netcoreapp2.0;netcoreapp3.0;net47;net48 false