From 9b827541e61fc7831804ce4ca1f2317ce759b817 Mon Sep 17 00:00:00 2001 From: alechkos <93551621+alechkos@users.noreply.github.com> Date: Thu, 10 Aug 2023 07:24:06 +0300 Subject: [PATCH] fix for findImpl (#2390) --- src/util/Injected.js | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/util/Injected.js b/src/util/Injected.js index d73115f..28ca4b4 100644 --- a/src/util/Injected.js +++ b/src/util/Injected.js @@ -80,6 +80,12 @@ exports.ExposeStore = (moduleRaidStr) => { }; } + if (window.mR.findModule('ChatCollection')[0] && window.mR.findModule('ChatCollection')[0].ChatCollection) { + if (typeof window.mR.findModule('ChatCollection')[0].ChatCollection.findImpl === 'undefined' && typeof window.mR.findModule('ChatCollection')[0].ChatCollection._find != 'undefined') { + window.mR.findModule('ChatCollection')[0].ChatCollection.findImpl = window.mR.findModule('ChatCollection')[0].ChatCollection._find; + } + } + // TODO remove these once everybody has been updated to WWebJS with legacy sessions removed const _linkPreview = window.mR.findModule('queryLinkPreview'); if (_linkPreview && _linkPreview[0] && _linkPreview[0].default) {