Compare commits
1 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 246a5cb278 |
@@ -76,15 +76,6 @@ public sealed class TelegramAdapter : IMessangerAdapterSetup
|
|||||||
errorHandler: async (_, ex, ct2) =>
|
errorHandler: async (_, ex, ct2) =>
|
||||||
{
|
{
|
||||||
_logger.Log(LogLevel.Warn, $"{MessengerType} error.", ex);
|
_logger.Log(LogLevel.Warn, $"{MessengerType} error.", ex);
|
||||||
|
|
||||||
if (ex is ApiRequestException apiEx)
|
|
||||||
{
|
|
||||||
if (apiEx.ErrorCode == 409)
|
|
||||||
{
|
|
||||||
_logger.Log(LogLevel.Critical, $"{MessengerType} остановлен.");
|
|
||||||
await _.Close(ct2);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
await Task.CompletedTask;
|
await Task.CompletedTask;
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user