Fix multiple plugins (again)

This commit is contained in:
Nuckyz 2024-10-05 08:01:40 -03:00
parent 1e01f85217
commit b5f626d1ff
No known key found for this signature in database
GPG key ID: 440BF8296E1C4AD9
11 changed files with 64 additions and 98 deletions

View file

@ -74,10 +74,10 @@ export default definePlugin({
// This prevents the Message Requests tab from always hiding due to the previous patch (and is compatible with spam requests)
// In short, only the red badge is hidden. Button visibility behavior isn't changed.
{
find: ".getSpamChannelsCount();",
find: ".getSpamChannelsCount()",
predicate: () => settings.store.hideMessageRequestsCount,
replacement: {
match: /(?<=getSpamChannelsCount\(\);return )\i\.getMessageRequestsCount\(\)/,
match: /(?<=getSpamChannelsCount\(\),\i=)\i\.getMessageRequestsCount\(\)/,
replace: "$self.getRealMessageRequestCount()"
}
},