From aad96d536e29ab36db3637a3bdbf6e1c127cb2f6 Mon Sep 17 00:00:00 2001 From: levlam Date: Mon, 30 Mar 2020 15:20:37 +0300 Subject: [PATCH] Fix CHECK. GitOrigin-RevId: 02effd6bbb16e7b84c9df3f47a98dad94844ddc7 --- td/telegram/MessageEntity.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/td/telegram/MessageEntity.cpp b/td/telegram/MessageEntity.cpp index f98ca738..1576623f 100644 --- a/td/telegram/MessageEntity.cpp +++ b/td/telegram/MessageEntity.cpp @@ -3760,7 +3760,7 @@ Status fix_formatted_text(string &text, vector &entities, bool al result.resize(last_non_whitespace_pos + 1); while (!entities.empty() && entities.back().offset > last_non_whitespace_utf16_offset) { CHECK(entities.back().type == MessageEntity::Type::TextUrl || - entities.back().type == MessageEntity::Type::MentionName); + entities.back().type == MessageEntity::Type::MentionName || is_pre_entity(entities.back().type)); entities.pop_back(); } bool need_sort = false;