diff --git a/src/store/userconfig.ts b/src/store/userconfig.ts index 2749f92..fddc728 100644 --- a/src/store/userconfig.ts +++ b/src/store/userconfig.ts @@ -50,8 +50,10 @@ export const useUserConfigStore = function(...args) { // Make sure we only register the listeners once if (!userConfigStore._initialized) { - subscribe('files:config:updated', function({ key, value }: { key: string, value: boolean }) { - userConfigStore.onUpdate(key, value) + subscribe('files:config:updated', (params) => { + if (params) { + userConfigStore.onUpdate(params.key, params.value) + } }) userConfigStore.onUpdate('_initialized', true) }