diff options
author | Nuckyz <61953774+Nuckyz@users.noreply.github.com> | 2023-03-23 02:11:28 -0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-03-23 02:11:28 -0300 |
commit | 7923a790e6c90847337d888bb906ab8222193248 (patch) | |
tree | 64e861070e6b2fc14b373e82f8de2ca3d6a52940 /src/plugins/apiMessagePopover.ts | |
parent | 1368c25824f3a0ef43457a5473085184a52f1523 (diff) | |
download | Vencord-7923a790e6c90847337d888bb906ab8222193248.tar.gz Vencord-7923a790e6c90847337d888bb906ab8222193248.tar.bz2 Vencord-7923a790e6c90847337d888bb906ab8222193248.zip |
Fix MessagePopoverAPI and any error Fake Nitro client theme bypass might have (#665)
Diffstat (limited to 'src/plugins/apiMessagePopover.ts')
-rw-r--r-- | src/plugins/apiMessagePopover.ts | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/plugins/apiMessagePopover.ts b/src/plugins/apiMessagePopover.ts index 0463c59..a17cac3 100644 --- a/src/plugins/apiMessagePopover.ts +++ b/src/plugins/apiMessagePopover.ts @@ -27,11 +27,11 @@ export default definePlugin({ find: "Messages.MESSAGE_UTILITIES_A11Y_LABEL", replacement: { // foo && !bar ? createElement(blah,...makeElement(addReactionData)) - match: /(\i&&!\i)\?\(0,\i\.jsxs?\)\(.{0,200}renderPopout:.{0,300}?(\i)\(.{3,20}\{key:"add-reaction".+?\}/, - replace: (m, bools, makeElement) => { + match: /\i&&!\i\?\(0,\i\.jsxs?\)\(.{0,200}renderPopout:.{0,300}?(\i)\(.{3,20}\{key:"add-reaction".+?\}/, + replace: (m, makeElement) => { const msg = m.match(/message:(.{1,3}),/)?.[1]; if (!msg) throw new Error("Could not find message variable"); - return `...(${bools}?Vencord.Api.MessagePopover._buildPopoverElements(${msg},${makeElement}):[]),${m}`; + return `...Vencord.Api.MessagePopover._buildPopoverElements(${msg},${makeElement}),${m}`; } } }], |