From f6765818d2248292b4dacf74c3ae3e2eae5856d4 Mon Sep 17 00:00:00 2001 From: Vendicated Date: Mon, 13 May 2024 03:34:01 +0200 Subject: [PATCH] ValidUser: fix rendering old mentions when message is edited Fixes https://github.com/Vendicated/Vencord/issues/2451 --- src/plugins/pinDms/index.tsx | 2 +- src/plugins/validUser/index.tsx | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/plugins/pinDms/index.tsx b/src/plugins/pinDms/index.tsx index 79503b9a..60484561 100644 --- a/src/plugins/pinDms/index.tsx +++ b/src/plugins/pinDms/index.tsx @@ -83,7 +83,7 @@ export default definePlugin({ // Rendering { match: /"renderRow",(\i)=>{(?<="renderDM",.+?(\i\.default),\{channel:.+?)/, - replace: "$&if($self.isChannelIndex($1.section, $1.row))return $self.renderChannel($1.section,$1.row,$2);" + replace: "$&if($self.isChannelIndex($1.section, $1.row))return $self.renderChannel($1.section,$1.row,$2)();" }, { match: /"renderSection",(\i)=>{/, diff --git a/src/plugins/validUser/index.tsx b/src/plugins/validUser/index.tsx index fd88ca9c..64b734f5 100644 --- a/src/plugins/validUser/index.tsx +++ b/src/plugins/validUser/index.tsx @@ -23,7 +23,7 @@ import { sleep } from "@utils/misc"; import { Queue } from "@utils/Queue"; import definePlugin from "@utils/types"; import { Constants, FluxDispatcher, RestAPI, UserProfileStore, UserStore, useState } from "@webpack/common"; -import type { ComponentType, ReactNode } from "react"; +import { type ComponentType, type ReactNode } from "react"; // LYING to the type checker here const UserFlags = Constants.UserFlags as Record; @@ -205,6 +205,7 @@ export default definePlugin({ return (