@fireproof/core 0.5.16 → 0.5.17
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/src/clock.js +2 -2
- package/dist/src/fireproof.js +117 -151
- package/dist/src/fireproof.js.map +1 -1
- package/dist/src/fireproof.mjs +117 -151
- package/dist/src/fireproof.mjs.map +1 -1
- package/dist/src/sync.js +1 -1
- package/package.json +1 -1
- package/src/clock.js +2 -2
- package/src/sync.js +1 -1
package/dist/src/sync.js
CHANGED
package/package.json
CHANGED
package/src/clock.js
CHANGED
@@ -237,12 +237,12 @@ export async function findEventsToSync (blocks, head) {
|
|
237
237
|
// console.time(callTag + '.findCommonAncestorWithSortedEvents')
|
238
238
|
const { ancestor, sorted } = await findCommonAncestorWithSortedEvents(events, head)
|
239
239
|
// console.timeEnd(callTag + '.findCommonAncestorWithSortedEvents')
|
240
|
-
// console.log('sorted', !!ancestor, sorted
|
240
|
+
// console.log('sorted', !!ancestor, sorted)
|
241
241
|
// console.time(callTag + '.contains')
|
242
242
|
|
243
243
|
const toSync = ancestor ? await asyncFilter(sorted, async uks => !(await contains(events, ancestor, uks.cid))) : sorted
|
244
244
|
// console.timeEnd(callTag + '.contains')
|
245
|
-
|
245
|
+
console.log('optimize sorted', !!ancestor, sorted.length - toSync.length)
|
246
246
|
|
247
247
|
return { cids: events, events: toSync }
|
248
248
|
}
|