Fix PinDMs and BetterSettings eager load

This commit is contained in:
Nuckyz 2025-01-15 11:17:40 -03:00
parent a53257634e
commit c8f4ce9785
No known key found for this signature in database
GPG key ID: 440BF8296E1C4AD9
3 changed files with 3 additions and 3 deletions

View file

@ -114,7 +114,7 @@ export default definePlugin({
{ // Load menu TOC eagerly
find: "#{intl::USER_SETTINGS_WITH_BUILD_OVERRIDE}",
replacement: {
match: /(\i)\(this,"handleOpenSettingsContextMenu",.{0,100}?null!=\i&&.{0,100}?(await Promise\.all[^};]*?\)\)).*?,(?=\1\(this)/,
match: /(\i)\(this,"handleOpenSettingsContextMenu",.{0,100}?null!=\i&&.{0,100}?(await [^};]*?\)\)).*?,(?=\1\(this)/,
replace: "$&(async ()=>$2)(),"
},
predicate: () => settings.store.eagerLoad