diff options
author | Vijay A <vraravam@users.noreply.github.com> | 2023-05-24 06:57:50 +0530 |
---|---|---|
committer | Vijay Aravamudhan <vraravam@users.noreply.github.com> | 2023-05-24 16:40:43 +0530 |
commit | e245b4fa229bee1e2ab97fcb42de3831b8bdbe5b (patch) | |
tree | d684777b3fde5470c9f99304a9f022422ffb8045 /src/stores/SettingsStore.ts | |
parent | 6.3.0-nightly.9 [skip ci] (diff) | |
download | ferdium-app-e245b4fa229bee1e2ab97fcb42de3831b8bdbe5b.tar.gz ferdium-app-e245b4fa229bee1e2ab97fcb42de3831b8bdbe5b.tar.zst ferdium-app-e245b4fa229bee1e2ab97fcb42de3831b8bdbe5b.zip |
Upgrade npm modules
Diffstat (limited to 'src/stores/SettingsStore.ts')
-rw-r--r-- | src/stores/SettingsStore.ts | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/stores/SettingsStore.ts b/src/stores/SettingsStore.ts index 811bc6f76..5ca499160 100644 --- a/src/stores/SettingsStore.ts +++ b/src/stores/SettingsStore.ts | |||
@@ -157,10 +157,7 @@ export default class SettingsStore extends TypedStore { | |||
157 | 157 | ||
158 | @action async _update({ type, data }): Promise<void> { | 158 | @action async _update({ type, data }): Promise<void> { |
159 | const appSettings = this.all; | 159 | const appSettings = this.all; |
160 | if (!this.fileSystemSettingsTypes.includes(type)) { | 160 | if (this.fileSystemSettingsTypes.includes(type)) { |
161 | debug('Update settings', type, data, this.all); | ||
162 | localStorage.setItem(type, Object.assign(appSettings[type], data)); | ||
163 | } else { | ||
164 | debug('Update settings on file system', type, data); | 161 | debug('Update settings on file system', type, data); |
165 | ipcRenderer.send('updateAppSettings', { | 162 | ipcRenderer.send('updateAppSettings', { |
166 | type, | 163 | type, |
@@ -168,6 +165,9 @@ export default class SettingsStore extends TypedStore { | |||
168 | }); | 165 | }); |
169 | 166 | ||
170 | Object.assign(this._fileSystemSettingsCache[type], data); | 167 | Object.assign(this._fileSystemSettingsCache[type], data); |
168 | } else { | ||
169 | debug('Update settings', type, data, this.all); | ||
170 | localStorage.setItem(type, Object.assign(appSettings[type], data)); | ||
171 | } | 171 | } |
172 | } | 172 | } |
173 | 173 | ||