1
0
mirror of https://github.com/laurent22/joplin.git synced 2024-12-24 10:27:10 +02:00

Initialize keychain service when starting mobile app

This commit is contained in:
Roman Musin 2020-06-04 21:56:43 +01:00
parent 2b322352ed
commit 959a8b59d1

View File

@ -65,6 +65,9 @@ const WelcomeUtils = require('lib/WelcomeUtils');
const { themeStyle } = require('lib/components/global-style.js');
const { uuid } = require('lib/uuid.js');
const { loadKeychainServiceAndSettings } = require('lib/services/SettingUtils');
const KeychainServiceDriverMobile = require('lib/services/keychain/KeychainServiceDriver.mobile').default;
const SyncTargetRegistry = require('lib/SyncTargetRegistry.js');
const SyncTargetOneDrive = require('lib/SyncTargetOneDrive.js');
const SyncTargetFilesystem = require('lib/SyncTargetFilesystem.js');
@ -444,7 +447,8 @@ async function initialize(dispatch) {
reg.logger().info('Database is ready.');
reg.logger().info('Loading settings...');
await Setting.load();
await loadKeychainServiceAndSettings(KeychainServiceDriverMobile);
if (!Setting.value('clientId')) Setting.setValue('clientId', uuid.create());