2
0
mirror of https://github.com/telegramdesktop/tdesktop synced 2025-08-31 06:26:18 +00:00

Simplify CustomEmojiId.

This commit is contained in:
John Preston
2022-08-15 13:17:24 +03:00
parent f0f7318978
commit c126a1e56e
5 changed files with 12 additions and 32 deletions

View File

@@ -87,11 +87,10 @@ QString FieldTagMimeProcessor::operator()(QStringView mimeTag) {
} else if (Ui::InputField::IsCustomEmojiLink(tag)) {
const auto data = Ui::InputField::CustomEmojiEntityData(tag);
const auto emoji = Data::ParseCustomEmojiData(data);
if (emoji.selfId != id) {
if (!emoji.id) {
i = all.erase(i);
continue;
}
if (!_session->premium()) {
} else if (!_session->premium()) {
const auto document = _session->data().document(emoji.id);
if (document->isPremiumEmoji()) {
if (!_allowPremiumEmoji