From 40395d562aeadaeaa88c5bc106797ea5a4ee51e4 Mon Sep 17 00:00:00 2001
From: Nuckyz <61953774+Nuckyz@users.noreply.github.com>
Date: Wed, 8 Mar 2023 00:11:59 -0300
Subject: Improvements for patches and misc stuff (#582)

---
 src/plugins/whoReacted.tsx | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

(limited to 'src/plugins/whoReacted.tsx')

diff --git a/src/plugins/whoReacted.tsx b/src/plugins/whoReacted.tsx
index 8ab1c5f..4b1c828 100644
--- a/src/plugins/whoReacted.tsx
+++ b/src/plugins/whoReacted.tsx
@@ -93,8 +93,8 @@ export default definePlugin({
     patches: [{
         find: ",reactionRef:",
         replacement: {
-            match: /((.)=(.{1,3})\.hideCount)(,.+?reactionCount.+?\}\))/,
-            replace: "$1,whoReactedProps=$3$4,$2?null:$self.renderUsers(whoReactedProps)"
+            match: /(?<=(\i)=(\i)\.hideCount,)(.+?reactionCount.+?\}\))/,
+            replace: (_, hideCount, props, rest) => `whoReactedProps=${props},${rest},${hideCount}?null:$self.renderUsers(whoReactedProps)`
         }
     }],
 
-- 
cgit 

