trilium/public/javascripts/sync.js

16 lines
360 B
JavaScript
Raw Normal View History

"use strict";
async function syncNow() {
const result = await server.post('sync/now');
if (result.success) {
showMessage("Sync finished successfully.");
}
else {
if (result.message.length > 50) {
result.message = result.message.substr(0, 50);
}
showError("Sync failed: " + result.message);
}
2017-10-29 23:22:41 +08:00
}