mirror of
https://github.com/zadam/trilium.git
synced 2025-03-01 14:22:32 +01:00
fix sync check - it was always reporting success even in failure cases
This commit is contained in:
parent
47d61c416d
commit
b5480b4137
@ -13,13 +13,13 @@ const dateUtils = require('../../services/date_utils');
|
|||||||
const entityConstructor = require('../../entities/entity_constructor');
|
const entityConstructor = require('../../entities/entity_constructor');
|
||||||
const utils = require('../../services/utils');
|
const utils = require('../../services/utils');
|
||||||
|
|
||||||
function testSync() {
|
async function testSync() {
|
||||||
try {
|
try {
|
||||||
if (!syncOptions.isSyncSetup()) {
|
if (!syncOptions.isSyncSetup()) {
|
||||||
return { success: false, message: "Sync server host is not configured. Please configure sync first." };
|
return { success: false, message: "Sync server host is not configured. Please configure sync first." };
|
||||||
}
|
}
|
||||||
|
|
||||||
syncService.login();
|
await syncService.login();
|
||||||
|
|
||||||
// login was successful so we'll kick off sync now
|
// login was successful so we'll kick off sync now
|
||||||
// this is important in case when sync server has been just initialized
|
// this is important in case when sync server has been just initialized
|
||||||
|
Loading…
x
Reference in New Issue
Block a user