mirror of
https://github.com/jeffvli/feishin.git
synced 2026-05-10 04:30:25 +02:00
remove release_channel from settings sync
This commit is contained in:
@@ -68,10 +68,12 @@ export const useSyncSettingsToMain = () => {
|
|||||||
mainStoreKey: 'disable_auto_updates',
|
mainStoreKey: 'disable_auto_updates',
|
||||||
rendererValue: settings.window.disableAutoUpdate,
|
rendererValue: settings.window.disableAutoUpdate,
|
||||||
},
|
},
|
||||||
{
|
// For some reason after the application is updated, the release channel from the
|
||||||
mainStoreKey: 'release_channel',
|
// renderer is always set to the latest channel. This causes an infinite update loop
|
||||||
rendererValue: settings.window.releaseChannel,
|
// {
|
||||||
},
|
// mainStoreKey: 'release_channel',
|
||||||
|
// rendererValue: settings.window.releaseChannel,
|
||||||
|
// },
|
||||||
{
|
{
|
||||||
mainStoreKey: 'window_enable_tray',
|
mainStoreKey: 'window_enable_tray',
|
||||||
rendererValue: settings.window.tray,
|
rendererValue: settings.window.tray,
|
||||||
@@ -110,13 +112,19 @@ export const useSyncSettingsToMain = () => {
|
|||||||
JSON.stringify(mainValueNormalized) !== JSON.stringify(rendererValueNormalized)
|
JSON.stringify(mainValueNormalized) !== JSON.stringify(rendererValueNormalized)
|
||||||
) {
|
) {
|
||||||
hasDifferences = true;
|
hasDifferences = true;
|
||||||
|
logFn.warn(logMsg.system.settingsSynchronized, {
|
||||||
|
meta: {
|
||||||
|
mainStoreKey: mapping.mainStoreKey,
|
||||||
|
mainValue: mainValueNormalized,
|
||||||
|
rendererValue: rendererValueNormalized,
|
||||||
|
},
|
||||||
|
});
|
||||||
localSettings.set(mapping.mainStoreKey, rendererValue);
|
localSettings.set(mapping.mainStoreKey, rendererValue);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Show restart toast if there were differences
|
// Show restart toast if there were differences
|
||||||
if (hasDifferences) {
|
if (hasDifferences) {
|
||||||
logFn.info(logMsg.system.settingsSynchronized);
|
|
||||||
openRestartRequiredToast(
|
openRestartRequiredToast(
|
||||||
i18n.t('error.settingsSyncError', { postProcess: 'sentenceCase' }),
|
i18n.t('error.settingsSyncError', { postProcess: 'sentenceCase' }),
|
||||||
);
|
);
|
||||||
|
|||||||
Reference in New Issue
Block a user