Fix some hidden channels not collapsing

This commit is contained in:
Nuckyz 2023-10-26 18:10:32 -03:00
parent 2f94e167c4
commit 0847f205b8
No known key found for this signature in database
GPG key ID: 440BF8296E1C4AD9

View file

@ -74,6 +74,10 @@ export default definePlugin({
match: /if\(!\i\.\i\.can\(\i\.\i\.VIEW_CHANNEL.+?{if\(this\.id===\i\).+?threadIds:\i}}/,
replace: ""
},
{
match: /(?=!1===\i.\i\.hasRelevantUnread\(this\.record\))/,
replace: "$self.isHiddenChannel(this.record)||"
},
{
match: /(?<=renderLevel:(\i\(this,\i\)\?\i\.Show:\i\.WouldShowIfUncollapsed).+?renderLevel:).+?(?=,)/,
replace: (_, renderLevelExpression) => renderLevelExpression