diff --git a/packages/isomorphic-core/src/delta-stream-builder.js b/packages/isomorphic-core/src/delta-stream-builder.js index ba46bbbc7..1f32fe902 100644 --- a/packages/isomorphic-core/src/delta-stream-builder.js +++ b/packages/isomorphic-core/src/delta-stream-builder.js @@ -10,7 +10,10 @@ const stream = require('stream'); * the inflated model they reference. */ function inflateTransactions(db, accountId, transactions = [], sourceName) { - const transactionJSONs = transactions.map((t) => (t.toJSON ? t.toJSON() : t)) + const transactionJSONs = transactions + .filter((t) => t.event !== 'delete') + .map((t) => (t.toJSON ? t.toJSON() : t)) + transactionJSONs.forEach((t) => { t.cursor = t.id; t.accountId = accountId;