sync are sent upon DB commit

This commit is contained in:
zadam
2020-01-31 22:32:24 +01:00
parent 05b51c0f68
commit eeedb91ef7
8 changed files with 50 additions and 24 deletions

View File

@@ -21,6 +21,18 @@ function isEntityEventsDisabled() {
return !!namespace.get('disableEntityEvents');
}
function getSyncRows() {
return namespace.get('syncRows') || [];
}
function addSyncRow(syncRow) {
const syncRows = getSyncRows();
syncRows.push(syncRow);
namespace.set('syncRows', syncRows);
}
function reset() {
clsHooked.reset();
}
@@ -32,5 +44,7 @@ module.exports = {
getSourceId,
disableEntityEvents,
isEntityEventsDisabled,
reset
reset,
getSyncRows,
addSyncRow
};