обработка Ошибка: Bad Request: message is not modified: specified new message content and reply markup are exactly the same as a current content and reply markup of the message

This commit is contained in:
Professional 2025-03-19 16:14:02 +07:00
parent dc1277f0e5
commit 23e5bffd9f

View File

@ -317,13 +317,14 @@ class Program
}
});
await botClient.EditMessageText(
chatId: chatId,
messageId: messageId,
text: $"Заявка #{reportId}\n\nОписание: {description}\nСтатус: {status}",
replyMarkup: statusButtons
);
string newText = $"Заявка #{reportId}\n\nОписание: {description}\nСтатус: {status}";
await botClient.EditMessageText(
chatId: chatId,
messageId: messageId,
text: newText,
replyMarkup: statusButtons
);
}
}
}
@ -335,6 +336,8 @@ class Program
}
private static async Task UpdateReportStatus(long reportId, string newStatus)
{
try