From 4aef1ffea1ede79ad60ffb9e146489678fe4654c Mon Sep 17 00:00:00 2001 From: Lavyk Soares Nunes Date: Thu, 26 Sep 2024 00:35:32 -0300 Subject: [PATCH] fix: openChatWindow (#3293) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * correção função openChatWindow Alterando o "chat" para "chatId" * fix: use defined variable The bug found here: https://github.com/pedroslopez/whatsapp-web.js/pull/3291#discussion_r1776061417 Co-authored-by: StiflerPasha <40593009+StiflerPasha@users.noreply.github.com> --------- Co-authored-by: alechkos <93551621+alechkos@users.noreply.github.com> Co-authored-by: StiflerPasha <40593009+StiflerPasha@users.noreply.github.com> --- src/util/InterfaceController.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/util/InterfaceController.js b/src/util/InterfaceController.js index cb18ce9..1f38931 100644 --- a/src/util/InterfaceController.js +++ b/src/util/InterfaceController.js @@ -16,7 +16,7 @@ class InterfaceController { async openChatWindow(chatId) { await this.pupPage.evaluate(async chatId => { const chatWid = window.Store.WidFactory.createWid(chatId); - const chat = window.Store.Chat.get(chat) || await window.Store.Chat.find(chatWid); + const chat = window.Store.Chat.get(chatWid) || await window.Store.Chat.find(chatWid); await window.Store.Cmd.openChatBottom(chat); }, chatId); }