1
0
mirror of https://github.com/laurent22/joplin.git synced 2025-11-26 22:41:17 +02:00

All: Added mechanism to migrate default settings to new values

This commit is contained in:
Laurent Cozic
2021-10-18 12:37:25 +01:00
parent 7d62df8906
commit 72db8e469d
4 changed files with 145 additions and 19 deletions

View File

@@ -787,15 +787,17 @@ export default class BaseApplication {
const locale = shim.detectAndSetLocale(Setting);
reg.logger().info(`First start: detected locale as ${locale}`);
Setting.skipDefaultMigrations();
if (Setting.value('env') === 'dev') {
Setting.setValue('showTrayIcon', 0);
Setting.setValue('autoUpdateEnabled', 0);
Setting.setValue('sync.interval', 3600);
}
Setting.setValue('sync.target', 0);
Setting.setValue('firstStart', 0);
} else {
Setting.applyDefaultMigrations();
setLocale(Setting.value('locale'));
}