@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/sync.js CHANGED
@@ -147,7 +147,7 @@ export class Sync {
147
147
  destroy() {
148
148
  this.database.blocks.syncs.delete(this);
149
149
  this.status = 'destroyed';
150
- this.peer.destroy();
150
+ // this.peer.destroy() todo
151
151
  }
152
152
  async sendUpdate(blockstore) {
153
153
  if (!this.peer || !this.isReady)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fireproof/core",
3
- "version": "0.5.16",
3
+ "version": "0.5.17",
4
4
  "description": "Cloudless database for apps, the browser, and IPFS",
5
5
  "main": "dist/src/fireproof.js",
6
6
  "module": "dist/src/fireproof.mjs",
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.length)
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
- // console.log('optimize sorted', !!ancestor, sorted.length - toSync.length)
245
+ console.log('optimize sorted', !!ancestor, sorted.length - toSync.length)
246
246
 
247
247
  return { cids: events, events: toSync }
248
248
  }
package/src/sync.js CHANGED
@@ -156,7 +156,7 @@ export class Sync {
156
156
  destroy () {
157
157
  this.database.blocks.syncs.delete(this)
158
158
  this.status = 'destroyed'
159
- this.peer.destroy()
159
+ // this.peer.destroy() todo
160
160
  }
161
161
 
162
162
  async sendUpdate (blockstore) {