From ab1e82d2c3ff91c07faf373a13e90b521ebb78fd Mon Sep 17 00:00:00 2001 From: orkestral Date: Thu, 2 Sep 2021 20:42:29 -0300 Subject: [PATCH] fix: lint code concert --- src/lib/wapi/store/get-store.js | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/src/lib/wapi/store/get-store.js b/src/lib/wapi/store/get-store.js index 17b5a3835..a677e856b 100644 --- a/src/lib/wapi/store/get-store.js +++ b/src/lib/wapi/store/get-store.js @@ -89,19 +89,21 @@ export async function getStore(modules) { window.Store.SendTextMsgToChat(this, ...arguments); }; - if(!window.Store.Chat._find) { - window.Store.Chat._find = e => { - const target = window.Store.Chat.get(e); - return target ? Promise.resolve(target) : Promise.resolve({ + if (!window.Store.Chat._find) { + window.Store.Chat._find = (e) => { + const target = window.Store.Chat.get(e); + return target + ? Promise.resolve(target) + : Promise.resolve({ id: e - }); + }); }; -} + } if (window.Store.MediaCollection) window.Store.MediaCollection.prototype.processFiles = window.Store.MediaCollection.prototype.processFiles || window.Store.MediaCollection.prototype.processAttachments; - + return window.Store; }