fix: Use global.savedUIState instead of ui_default

savedUIState isn't a normal UI_default, so it doesn't show up in the
ui_defaults list, and we can't fetch it with our prefs helper. Instead,
we should use the property on window

As a followup, it may be nice to make savedUIState be treated like a
normal ui_default, but I think that an overhaul of server-side
ui_default stuff is too risky for now

Signed-off-by: Skyler Grey <skyler.grey@collabora.com>
Change-Id: Ia66570c4694608a5caf7feba60208f34ca3c8ad3
This commit is contained in:
Skyler Grey 2024-06-06 12:33:32 +00:00 committed by Skyler Grey
parent 772339446c
commit f93a9ee086

View file

@ -325,7 +325,7 @@ window.app = {
const uiDefault = global.prefs._getUIDefault(key);
if (
global.prefs._getUIDefault('SavedUIState', 'true').toLowerCase() === 'false' &&
!global.savedUIState &&
uiDefault !== undefined
) {
return uiDefault;