Skip to content
This repository has been archived by the owner on Sep 10, 2024. It is now read-only.

Commit

Permalink
修复
Browse files Browse the repository at this point in the history
  • Loading branch information
Yushu2606 committed Aug 9, 2023
1 parent 760fc5d commit f9cc711
Showing 1 changed file with 14 additions and 2 deletions.
16 changes: 14 additions & 2 deletions src/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,13 @@
{
continue;
}
await botClient.DeleteMessageAsync(update.Message.Chat.Id, data[member.Id]);
try
{
await botClient.DeleteMessageAsync(update.Message.Chat.Id, data[member.Id]);
}
catch (ApiRequestException)
{
}
data.Remove(member.Id);
}
break;
Expand Down Expand Up @@ -125,7 +131,13 @@
return;
}
members.Remove(update.ChatJoinRequest.UserChatId);
await botClient.DeleteMessageAsync(update.ChatJoinRequest.Chat.Id, msg.MessageId);
try
{
await botClient.DeleteMessageAsync(update.ChatJoinRequest.Chat.Id, msg.MessageId);
}
catch (ApiRequestException)
{
}
}
catch (Exception ex)
{
Expand Down

0 comments on commit f9cc711

Please sign in to comment.