BetterSettings: remove duplicate "Other options" menu entries (#3727)

Co-authored-by: V <vendicated@riseup.net>
This commit is contained in:
Elvyra 2025-10-22 22:33:14 +02:00 • committed by GitHub
parent e9fd7db6e6
commit ebe2b2769c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -171,10 +171,11 @@ export default definePlugin({
},
wrapMap(toWrap: any[]) {
const otherOptions = getIntlMessage("OTHER_OPTIONS");
// @ts-expect-error
toWrap.map = function (render: (item: SettingsEntry) => ReactElement<any>) {
return this
.filter(a => a.items.length > 0)
.filter(a => a.items.length > 0 && a.label !== otherOptions)
.map(({ label, items }) => {
const children = items.map(render);
if (label) {