From e55c2067336d8c1e5d45d23c70f267bea5e48dbe Mon Sep 17 00:00:00 2001 From: BrunoSobrino Date: Sat, 5 Oct 2024 19:13:05 -0600 Subject: [PATCH] =?UTF-8?q?Revert=20"=E3=82=9E=20=F0=9D=90=86=F0=9D=90=9A?= =?UTF-8?q?=F0=9D=90=9B=F0=9D=90=AB=F0=9D=90=A2=F0=9D=90=9E=F0=9D=90=A5=20?= =?UTF-8?q?=F0=9D=90=92=F0=9D=90=A4=20=E3=81=81"?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This reverts commit 720ec0aa519d9b3d75ff2e931a528476c5177b5d. --- src/libraries/store.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/libraries/store.js b/src/libraries/store.js index 71b7ce5dd1..5f8b40d859 100644 --- a/src/libraries/store.js +++ b/src/libraries/store.js @@ -16,7 +16,7 @@ * Ciphertext error fix and additional improvements by @BrunoSobrino * See: https://github.com/BrunoSobrino */ -const { BufferJSON, isJidBroadcast, WAMessageStubType, updateMessageWithReceipt, updateMessageWithReaction, jidNormalizedUser, proto } = (await import('baileys')).default; +const { BufferJSON, proto, isJidBroadcast, WAMessageStubType, updateMessageWithReceipt, updateMessageWithReaction, jidNormalizedUser } = (await import('baileys')).default; const TIME_TO_DATA_STALE = 5 * 60 * 1000; @@ -70,7 +70,7 @@ function makeInMemoryStore() { for (const msg of newMessages) { const jid = msg.key.remoteJid?.decodeJid?.(); if (!jid || isJidBroadcast(jid)) continue; - upsertMessage(jid, WAWeb.WebMessageInfo.fromObject(msg), type); + upsertMessage(jid, proto.WebMessageInfo.fromObject(msg), type); } } }); @@ -155,7 +155,7 @@ function makeInMemoryStore() { function fromJSON(json) { Object.assign(chats, json.chats); for (const jid in json.messages) { - messages[jid] = json.messages[jid].map(m => m && WAWeb.WebMessageInfo.fromObject(m)); + messages[jid] = json.messages[jid].map(m => m && proto.WebMessageInfo.fromObject(m)); } }