From f7ae4faeb0db91dfe62c5cf5ba3d123e799e9198 Mon Sep 17 00:00:00 2001 From: jeffvli Date: Sun, 19 Jul 2026 12:35:19 -0700 Subject: [PATCH] fix tag editor defaults to set sort tags to non-multi --- src/renderer/store/settings.store.ts | 24 ++++++++++++++++++++---- 1 file changed, 20 insertions(+), 4 deletions(-) diff --git a/src/renderer/store/settings.store.ts b/src/renderer/store/settings.store.ts index 5a7579158..ad0a13282 100644 --- a/src/renderer/store/settings.store.ts +++ b/src/renderer/store/settings.store.ts @@ -2052,7 +2052,7 @@ const initialState: SettingsState = { ALBUMARTISTSSORT: { autocompleteSource: 'serverArtists', customValues: [], - multiValue: true, + multiValue: false, }, artist: { autocompleteSource: 'serverArtists', @@ -2067,12 +2067,12 @@ const initialState: SettingsState = { artistSort: { autocompleteSource: 'serverArtists', customValues: [], - multiValue: true, + multiValue: false, }, ARTISTSSORT: { autocompleteSource: 'serverArtists', customValues: [], - multiValue: true, + multiValue: false, }, genre: { autocompleteSource: 'serverGenres', @@ -2705,10 +2705,26 @@ export const useSettingsStore = createWithEqualityFn()( } } + if (version < 32) { + const tagConfigs = state.tagEditor?.tagConfigs; + if (tagConfigs) { + for (const key of [ + 'albumArtistSort', + 'ALBUMARTISTSSORT', + 'artistSort', + 'ARTISTSSORT', + ] as const) { + if (tagConfigs[key]) { + tagConfigs[key].multiValue = false; + } + } + } + } + return persistedState; }, name: 'store_settings', - version: 31, + version: 32, }, ), );