@dxos/hypercore 0.1.55 → 0.1.56-main.09ca29d

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.
@@ -11282,16 +11282,33 @@ var import_hypercore2 = __toESM(require_hypercore());
11282
11282
 
11283
11283
  // packages/common/hypercore/src/crypto.ts
11284
11284
  import { callbackify } from "@dxos/node-std/util";
11285
- import invariant from "tiny-invariant";
11286
11285
  import { verifySignature } from "@dxos/crypto";
11286
+ import { invariant } from "@dxos/invariant";
11287
11287
  import { arrayToBuffer } from "@dxos/util";
11288
+ var __dxlog_file = "/home/runner/work/dxos/dxos/packages/common/hypercore/src/crypto.ts";
11288
11289
  var createCodecEncoding = (codec, opts) => ({
11289
11290
  encode: (obj) => arrayToBuffer(codec.encode(obj, opts)),
11290
11291
  decode: (buffer) => codec.decode(buffer, opts)
11291
11292
  });
11292
11293
  var createCrypto = (signer, publicKey) => {
11293
- invariant(signer);
11294
- invariant(publicKey);
11294
+ invariant(signer, void 0, {
11295
+ F: __dxlog_file,
11296
+ L: 27,
11297
+ S: void 0,
11298
+ A: [
11299
+ "signer",
11300
+ ""
11301
+ ]
11302
+ });
11303
+ invariant(publicKey, void 0, {
11304
+ F: __dxlog_file,
11305
+ L: 28,
11306
+ S: void 0,
11307
+ A: [
11308
+ "publicKey",
11309
+ ""
11310
+ ]
11311
+ });
11295
11312
  return {
11296
11313
  sign: (message, secretKey, cb) => {
11297
11314
  callbackify(signer.sign.bind(signer))(publicKey, message, (err, result) => {
@@ -11337,7 +11354,7 @@ var defaultReplicateOptions = {
11337
11354
 
11338
11355
  // packages/common/hypercore/src/hypercore-factory.ts
11339
11356
  var import_hypercore = __toESM(require_hypercore());
11340
- import invariant2 from "tiny-invariant";
11357
+ import { invariant as invariant2 } from "@dxos/invariant";
11341
11358
  import { createStorage, StorageType } from "@dxos/random-access-storage";
11342
11359
 
11343
11360
  // packages/common/hypercore/src/util.ts
@@ -11345,6 +11362,7 @@ import util from "@dxos/node-std/util";
11345
11362
  var py = (obj, fn) => util.promisify(fn.bind(obj));
11346
11363
 
11347
11364
  // packages/common/hypercore/src/hypercore-factory.ts
11365
+ var __dxlog_file2 = "/home/runner/work/dxos/dxos/packages/common/hypercore/src/hypercore-factory.ts";
11348
11366
  var HypercoreFactory = class {
11349
11367
  // prettier-ignore
11350
11368
  constructor(_root = createStorage({
@@ -11352,7 +11370,15 @@ var HypercoreFactory = class {
11352
11370
  }).createDirectory(), _options) {
11353
11371
  this._root = _root;
11354
11372
  this._options = _options;
11355
- invariant2(this._root);
11373
+ invariant2(this._root, void 0, {
11374
+ F: __dxlog_file2,
11375
+ L: 22,
11376
+ S: this,
11377
+ A: [
11378
+ "this._root",
11379
+ ""
11380
+ ]
11381
+ });
11356
11382
  }
11357
11383
  /**
11358
11384
  * Creates a feed using a storage factory prefixed with the feed's key.