hypercore 11.16.1 → 11.16.2

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/lib/audit.js CHANGED
@@ -113,7 +113,7 @@ module.exports = async function auditCore (core, { tree = true, blocks = true, b
113
113
 
114
114
  const page = core.bitfield.getBitfield(index)
115
115
  if (page.bitfield) tx.putBitfieldPage(page.index, page.bitfield)
116
- else tx.deleteBitfieldPage(page.idnex)
116
+ else tx.deleteBitfieldPage(page.index)
117
117
  continue
118
118
  }
119
119
 
package/lib/bitfield.js CHANGED
@@ -492,7 +492,7 @@ module.exports = class Bitfield {
492
492
 
493
493
  const pages = Math.ceil(length / BITS_PER_PAGE)
494
494
  const buffer = b4a.alloc(pages * BYTES_PER_PAGE)
495
- const stream = storage.createBitfieldStream()
495
+ const stream = storage.createBitfieldStream({ lt: pages })
496
496
 
497
497
  for await (const { index, page } of stream) {
498
498
  buffer.set(page, index * BYTES_PER_PAGE)
package/lib/core.js CHANGED
@@ -815,9 +815,10 @@ async function getCoreInfo (storage) {
815
815
 
816
816
  r.tryFlush()
817
817
 
818
+ const [authInfo, headInfo, hintsInfo] = await Promise.all([auth, head, hints])
818
819
  return {
819
- ...await auth,
820
- head: await head,
821
- hints: await hints
820
+ ...authInfo,
821
+ head: headInfo,
822
+ hints: hintsInfo
822
823
  }
823
824
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "hypercore",
3
- "version": "11.16.1",
3
+ "version": "11.16.2",
4
4
  "description": "Hypercore is a secure, distributed append-only log",
5
5
  "main": "index.js",
6
6
  "scripts": {