Dependency Update

- downgrade NetStandard from 2.1 to 2.0 to allow .NetFramework usage from 4.6.1 to 4.8
- remove .Net Framework 4.7.2 compilation target
- replacing conditioned compilation for .Net Framework with .Net Standard
- removing System.Net.Http dependency (was only necessary for .Net Framework)
This commit is contained in:
FlorianDahn 2021-12-16 14:57:28 +01:00
parent 03565aba98
commit 3b8b24593f
2 changed files with 2 additions and 3 deletions

View File

@ -138,7 +138,7 @@ namespace TelegramBotBase.Form
{ {
var oldMessages = OldMessages.AsEnumerable(); var oldMessages = OldMessages.AsEnumerable();
#if !NET472 #if !NETSTANDARD2_0
while (oldMessages.Any()) while (oldMessages.Any())
{ {
using var cts = new CancellationTokenSource(); using var cts = new CancellationTokenSource();

View File

@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk"> <Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup> <PropertyGroup>
<TargetFrameworks>netstandard2.1;net472;net5;netcoreapp3.1;net6</TargetFrameworks> <TargetFrameworks>netstandard2.0;net5;netcoreapp3.1;net6</TargetFrameworks>
<GenerateAssemblyInfo>false</GenerateAssemblyInfo> <GenerateAssemblyInfo>false</GenerateAssemblyInfo>
<GeneratePackageOnBuild>False</GeneratePackageOnBuild> <GeneratePackageOnBuild>False</GeneratePackageOnBuild>
<PackageRequireLicenseAcceptance>true</PackageRequireLicenseAcceptance> <PackageRequireLicenseAcceptance>true</PackageRequireLicenseAcceptance>
@ -68,7 +68,6 @@
<ItemGroup> <ItemGroup>
<PackageReference Include="Newtonsoft.Json" Version="13.0.1" /> <PackageReference Include="Newtonsoft.Json" Version="13.0.1" />
<PackageReference Include="System.Net.Http" Version="4.3.4" />
<PackageReference Include="Telegram.Bot" Version="17.0.0" /> <PackageReference Include="Telegram.Bot" Version="17.0.0" />
<PackageReference Include="Telegram.Bot.Extensions.Polling" Version="1.0.0" /> <PackageReference Include="Telegram.Bot.Extensions.Polling" Version="1.0.0" />
</ItemGroup> </ItemGroup>