fix: video side can no longer change the music server via the shared settings page
The settings page is shared; on the video side its auto-save (debouncedAutoSave- Settings) still fired when editing VIDEO fields (TMDB key, watch region, autoplay), and saveSettings reads the server toggle from the DOM + persists active_media_ server — so clicking the toggle to Jellyfin on the video side and then editing any field would write active_media_server=jellyfin to the shared config (and trigger a full music save). Guard: never auto-save music settings while data-side=video. Video settings persist via /api/video/*; the toggle re-syncs to the real active server on every Settings load. One-way isolation restored.
This commit is contained in:
parent
b7ae32220b
commit
a4d6e78bce
1 changed files with 6 additions and 0 deletions
|
|
@ -45,6 +45,12 @@ function debouncedAutoSaveSettings() {
|
|||
// fields on load — those aren't user edits and must not trigger a full
|
||||
// save (which re-initializes every backend service client).
|
||||
if (window._suppressSettingsAutoSave) return;
|
||||
// ISOLATION: the video side reuses this shared settings page, so editing a
|
||||
// VIDEO field (TMDB key, region, autoplay…) would otherwise fire this MUSIC
|
||||
// auto-save — which reads the server toggle from the DOM and would persist
|
||||
// active_media_server, letting the video side change the music server. Video
|
||||
// settings save themselves via /api/video/*; never auto-save music here.
|
||||
if (document.body.getAttribute('data-side') === 'video') return;
|
||||
// #827: the Logs tab has no savable settings — its live-viewer controls
|
||||
// (source picker, filters, auto-scroll) were tripping the auto-save and
|
||||
// flooding app.log with "Settings saved" lines, drowning out the logs the
|
||||
|
|
|
|||
Loading…
Reference in a new issue