From 4ab084c0aca819f29c5397ea57387caa51a95695 Mon Sep 17 00:00:00 2001 From: Vendicated Date: Mon, 21 Jul 2025 12:13:13 +0200 Subject: [PATCH] make ShowMeYourName patch safer --- src/plugins/showMeYourName/index.tsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/plugins/showMeYourName/index.tsx b/src/plugins/showMeYourName/index.tsx index 5affa885..018fa305 100644 --- a/src/plugins/showMeYourName/index.tsx +++ b/src/plugins/showMeYourName/index.tsx @@ -50,7 +50,8 @@ export default definePlugin({ { find: '="SYSTEM_TAG"', replacement: { - match: /(?<=onContextMenu:\i,children:)\i\?/, + // The field is named "userName", but as this is unusual casing, the regex also matches username, in case they change it + match: /(?<=onContextMenu:\i,children:)\i\?(?=.{0,100}?user[Nn]ame:)/, replace: "$self.renderUsername(arguments[0]),_oldChildren:$&" } },