save initial formating while editing

This commit is contained in:
Dmitriy Pleshevskiy 2024-03-14 13:20:21 +03:00
parent 12ca31135f
commit c55983fd53
Signed by: pleshevskiy
GPG key ID: 17041163DA10A9A2

View file

@ -41,10 +41,11 @@ bot.on("channel_post", (msg) => {
taskEither.tryCatch(
() =>
bot.editMessageText(
msg.text + "\n\nYandexGpt:\n\n" + res,
msg.text + "\n\nYandexGPT:\n\n" + res,
{
chat_id: (msg.forward_from_chat ?? msg.chat).id,
message_id: msg.forward_from_message_id ?? msg.message_id,
entities: msg.entities,
},
),
String,