mirror of
				https://github.com/zadam/trilium.git
				synced 2025-10-31 18:36:30 +01:00 
			
		
		
		
	not sending ping to clients after every sync addition, only after commit which significantly speeds up imports
This commit is contained in:
		| @@ -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) { | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user