Fix BetterSettings

This commit is contained in:
thororen1234 2025-10-06 10:30:38 -04:00
parent cb82741fba
commit 44ead81b46
No known key found for this signature in database

View file

@ -126,7 +126,7 @@ export default definePlugin({
find: "#{intl::USER_SETTINGS_ACTIONS_MENU_LABEL}",
replacement: [
{
match: /(\(0,\i.\i\)\(\))(?=\.filter\(\i=>\{let\{section:\i\}=)/,
match: /(\i)(?=\.forEach\(\i=>\{let\{)/,
replace: "$self.wrapMenu($1)"
},
{
@ -170,9 +170,9 @@ export default definePlugin({
}
return {
filter(predicate: (item: SettingsEntry) => boolean) {
forEach(predicate: (item: SettingsEntry) => void) {
for (const category of items) {
category.items = category.items.filter(predicate);
category.items.forEach(predicate);
}
return this;
},