mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-06-05 06:33:57 +02:00
Don't show duplicated emoji set.
This commit is contained in:
parent
a2fe1506cc
commit
9a0ea78e0f
1 changed files with 10 additions and 0 deletions
|
@ -2114,6 +2114,16 @@ void EmojiListWidget::refreshCustom() {
|
||||||
: setId;
|
: setId;
|
||||||
if (!lookupId) {
|
if (!lookupId) {
|
||||||
return;
|
return;
|
||||||
|
} else if (!megagroup
|
||||||
|
&& !_custom.empty()
|
||||||
|
&& _custom.front().id == Data::Stickers::MegagroupSetId
|
||||||
|
&& _megagroupSet->mgInfo->emojiSet.id == setId) {
|
||||||
|
// Skip the set that is already added as a megagroup set.
|
||||||
|
return;
|
||||||
|
} else if (megagroup
|
||||||
|
&& ranges::contains(_custom, lookupId, &CustomSet::id)) {
|
||||||
|
// Skip the set that is already added as a custom set.
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
auto it = sets.find(lookupId);
|
auto it = sets.find(lookupId);
|
||||||
if (it == sets.cend()
|
if (it == sets.cend()
|
||||||
|
|
Loading…
Add table
Reference in a new issue