mirror of
https://github.com/zadam/trilium.git
synced 2025-06-06 18:08:33 +02:00
not sending ping to clients after every sync addition, only after commit which significantly speeds up imports
This commit is contained in:
parent
44219e7ccc
commit
3fa3e912a4
@ -209,6 +209,8 @@ async function transactional(func) {
|
|||||||
|
|
||||||
transactionActive = false;
|
transactionActive = false;
|
||||||
resolve();
|
resolve();
|
||||||
|
|
||||||
|
setTimeout(() => require('./ws').sendPingToAllClients(), 50);
|
||||||
}
|
}
|
||||||
catch (e) {
|
catch (e) {
|
||||||
if (transactionActive) {
|
if (transactionActive) {
|
||||||
|
@ -24,8 +24,6 @@ async function addEntitySync(entityName, entityId, sourceId) {
|
|||||||
const sync = await insertEntitySync(entityName, entityId, sourceId);
|
const sync = await insertEntitySync(entityName, entityId, sourceId);
|
||||||
|
|
||||||
syncs.push(sync);
|
syncs.push(sync);
|
||||||
|
|
||||||
setTimeout(() => require('./ws').sendPingToAllClients(), 50);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
async function addEntitySyncsForSector(entityName, entityPrimaryKey, sector) {
|
async function addEntitySyncsForSector(entityName, entityPrimaryKey, sector) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user