From d1d5c3074b1e17cf84b5051f518558a49cd1cabc Mon Sep 17 00:00:00 2001 From: Eduard Kuzmenko Date: Sat, 28 Nov 2020 18:47:45 +0200 Subject: [PATCH] =?UTF-8?q?Fix=20animated=20emoji=20such=20as=20"?= =?UTF-8?q?=F0=9F=A4=B7=E2=80=8D=E2=99=82=EF=B8=8F"?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/lib/appManagers/appStickersManager.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/lib/appManagers/appStickersManager.ts b/src/lib/appManagers/appStickersManager.ts index a9127952..f0892683 100644 --- a/src/lib/appManagers/appStickersManager.ts +++ b/src/lib/appManagers/appStickersManager.ts @@ -94,7 +94,8 @@ export class AppStickersManager { if(!stickerSet || !stickerSet.documents) return undefined; emoji = emoji.replace(/\ufe0f/g, '').replace(/🏻|🏼|🏽|🏾|🏿/g, ''); - return stickerSet.documents.find(doc => (doc as Document.document).stickerEmojiRaw == emoji); + const pack = stickerSet.packs.find(p => p.emoticon == emoji); + return pack ? appDocsManager.getDoc(pack.documents[0]) : undefined; } public saveStickerSet(res: Omit, id: string) {