fix: invalidate sort caches after metadata save, remove sort-debug logs

After saving sort tags via the metadata editor, invalidate _artistSortMap
and the apiCached getArtists entry so the updated Navidrome sortName values
are picked up on the next page visit without a hard refresh.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
HoneyandClaude Sonnet 4.6 committed 2026-06-08 23:34:12 +02:00
1 parent 85f8d758a5
commit 59adee60d5
3 files changed
+4 -6

No files matched your search

-2
View File
@@ -396,8 +396,6 @@ export async function loadAlbumDetail(album) {
const songs = r.album?.song || [];
const totalMin = Math.round(songs.reduce((s,t) => s+(t.duration||0), 0) / 60);
document.getElementById('album-detail-stats').textContent = `${songs.length} Titel · ${r.album.year||''} · ${totalMin} Min.`;
console.log('[sort-debug] r.album full:', JSON.stringify(r.album));
if (songs[0]) console.log('[sort-debug] songs[0] full:', JSON.stringify(songs[0]));
// r.album has sortName (album sort tag) — use it; nav album may not have sortName
document.getElementById('album-detail-name').textContent = dispAlbumName(r.album);
if (songs[0]) {