diff --git a/src/plugins/_api/messageEvents.ts b/src/plugins/_api/messageEvents.ts index 70b7f26c3..07a87debd 100644 --- a/src/plugins/_api/messageEvents.ts +++ b/src/plugins/_api/messageEvents.ts @@ -27,7 +27,7 @@ export default definePlugin({ { find: "#{intl::EDIT_TEXTAREA_HELP}", replacement: { - match: /(?<=,channel:\i\}\)\.then\().+?(?=\i\.content!==this\.props\.message\.content&&\i\((.+?)\)\})/, + match: /(?<=,channel:\i,message:\i\}\)\.then\().+?(?=\i\.content!==this\.props\.message\.content&&\i\((.+?)\)\})/, replace: (match, args) => "" + `async ${match}` + `if(await Vencord.Api.MessageEvents._handlePreEdit(${args}))` + diff --git a/src/plugins/decor/index.tsx b/src/plugins/decor/index.tsx index 927d0f3e6..292ae65bb 100644 --- a/src/plugins/decor/index.tsx +++ b/src/plugins/decor/index.tsx @@ -51,8 +51,8 @@ export default definePlugin({ find: "80,onlyAnimateOnHoverOrFocus:!", replacement: [ { - match: /(?<==)\i=>{let{children.{20,200}isSelected:\i.{0,5}\}=\i/, - replace: "$self.DecorationGridItem=$&", + match: /(?=function (\i)\(\i\){let{children.{20,200}isSelected:\i,\.\.\.\i\}=\i)/, + replace: "$self.DecorationGridItem=$1;", }, { match: /(?<==)\i=>{let{user:\i,avatarDecoration/, @@ -113,7 +113,7 @@ export default definePlugin({ find: "#{intl::PREMIUM_UPSELL_PROFILE_AVATAR_DECO_INLINE_UPSELL_DESCRIPTION}", replacement: [ { - match: /(?<==)\i=>{let{user:\i,guildId:\i,avatarDecoration:/, + match: /(?<==)function\(\i\){let{user:\i,guildId:\i,avatarDecoration:/, replace: "$self.AvatarDecorationModalPreview=$&" } ] diff --git a/src/plugins/fakeNitro/index.tsx b/src/plugins/fakeNitro/index.tsx index 5fac11ec2..325ac4519 100644 --- a/src/plugins/fakeNitro/index.tsx +++ b/src/plugins/fakeNitro/index.tsx @@ -386,8 +386,8 @@ export default definePlugin({ predicate: () => settings.store.transformEmojis, replacement: { // Add the fake nitro emoji notice - match: /(?<=emojiDescription:)(\i)(?<=\1=\(\i=>\{.+?\}\)\((\i)\)[,;].+?)/, - replace: (_, reactNode, props) => `$self.addFakeNotice(${FakeNoticeType.Emoji},${reactNode},!!${props}?.fakeNitroNode?.fake)` + match: /(?<=emojiDescription:)(\i)(?<=\1=function\(\i\)\{let\{sourceType:.+?)/, + replace: (_, reactNode) => `$self.addFakeNotice(${FakeNoticeType.Emoji},${reactNode},!!arguments[0]?.fakeNitroNode?.fake)` } }, // Separate patch for allowing using custom app icons diff --git a/src/plugins/noMosaic/index.ts b/src/plugins/noMosaic/index.ts index b5fffba00..b337c4f56 100644 --- a/src/plugins/noMosaic/index.ts +++ b/src/plugins/noMosaic/index.ts @@ -31,7 +31,7 @@ export default definePlugin({ find: '"PLAINTEXT_PREVIEW":"OTHER"', replacement: { match: /"IMAGE"===\i\|\|"VIDEO"===\i\|\|"CLIP"===\i/, - replace: "false" + replace: "(false)" } }, { diff --git a/src/plugins/showHiddenChannels/index.tsx b/src/plugins/showHiddenChannels/index.tsx index 46adc721f..4e2ca8cae 100644 --- a/src/plugins/showHiddenChannels/index.tsx +++ b/src/plugins/showHiddenChannels/index.tsx @@ -107,7 +107,7 @@ export default definePlugin({ replacement: [ { // Do not show confirmation to join a voice channel when already connected to another if clicking on a hidden voice channel - match: /(?<=getIgnoredUsersForVoiceChannel\((\i)\.id\)[^;]+?;return\()/, + match: /(?<=getIgnoredUsersForVoiceChannel\((\i)\.id\)[^;]{0,300}?;return\()/, replace: (_, channel) => `!$self.isHiddenChannel(${channel})&&` }, {