Добавлен метод удаления сообщения
This commit is contained in:
@@ -137,6 +137,18 @@ public sealed class TelegramAdapter : IMessengerAdapterSetup
|
||||
return null;
|
||||
}
|
||||
|
||||
/// <inheritdoc/>
|
||||
public Task DeleteAsync(string chatId, string messageId, CancellationToken ct = default)
|
||||
{
|
||||
if (_client is null)
|
||||
{
|
||||
_logger.Log(LogLevel.Critical, $"{MessengerType} client is not initialized.");
|
||||
return null;
|
||||
}
|
||||
|
||||
return _client.DeleteMessage(chatId, Convert.ToInt32(messageId), ct);
|
||||
}
|
||||
|
||||
// --- Helpers ---
|
||||
|
||||
private InlineKeyboardMarkup? BuildInlineMarkup(IEnumerable<IEnumerable<InlineButton>>? inline)
|
||||
|
||||
Reference in New Issue
Block a user