libp2p 1.8.2 → 1.8.3-0edbfe7af

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.
@@ -29,7 +29,7 @@ export function getPeerAddress(peer) {
29
29
  }
30
30
  else {
31
31
  const maPeerId = peerIdFromString(maPeerIdStr);
32
- if (peerId == null || !peerId.equals(maPeerId)) {
32
+ if (peerId?.equals(maPeerId) !== true) {
33
33
  throw new CodeError('Multiaddrs must all have the same peer id or have no peer id', codes.ERR_INVALID_PARAMETERS);
34
34
  }
35
35
  }
@@ -1 +1 @@
1
- {"version":3,"file":"get-peer.js","sourceRoot":"","sources":["../../src/get-peer.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAA;AACvD,OAAO,EAAE,gBAAgB,EAAE,MAAM,iBAAiB,CAAA;AAClD,OAAO,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAA;AACrD,OAAO,EAAE,KAAK,EAAE,MAAM,aAAa,CAAA;AASnC;;GAEG;AACH,MAAM,UAAU,cAAc,CAAE,IAAsC;IACpE,IAAI,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC;QACnB,OAAO,EAAE,MAAM,EAAE,IAAI,EAAE,UAAU,EAAE,EAAE,EAAE,CAAA;IACzC,CAAC;IAED,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,IAAI,CAAC,EAAE,CAAC;QACzB,IAAI,GAAG,CAAC,IAAI,CAAC,CAAA;IACf,CAAC;IAED,IAAI,MAA0B,CAAA;IAE9B,IAAI,IAAI,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;QACpB,MAAM,SAAS,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,SAAS,EAAE,CAAA;QACrC,MAAM,GAAG,SAAS,IAAI,IAAI,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,gBAAgB,CAAC,SAAS,CAAC,CAAA;QAEpE,mDAAmD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,3 +1,3 @@
1
- export declare const version = "1.8.2";
1
+ export declare const version = "1.8.3-0edbfe7af";
2
2
  export declare const name = "libp2p";
3
3
  //# sourceMappingURL=version.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"version.d.ts","sourceRoot":"","sources":["../../src/version.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,OAAO,UAAU,CAAA;AAC9B,eAAO,MAAM,IAAI,WAAW,CAAA"}
1
+ {"version":3,"file":"version.d.ts","sourceRoot":"","sources":["../../src/version.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,OAAO,oBAAoB,CAAA;AACxC,eAAO,MAAM,IAAI,WAAW,CAAA"}
@@ -1,3 +1,3 @@
1
- export const version = '1.8.2';
1
+ export const version = '1.8.3-0edbfe7af';
2
2
  export const name = 'libp2p';
3
3
  //# sourceMappingURL=version.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"version.js","sourceRoot":"","sources":["../../src/version.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,OAAO,GAAG,OAAO,CAAA;AAC9B,MAAM,CAAC,MAAM,IAAI,GAAG,QAAQ,CAAA"}
1
+ {"version":3,"file":"version.js","sourceRoot":"","sources":["../../src/version.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,OAAO,GAAG,iBAAiB,CAAA;AACxC,MAAM,CAAC,MAAM,IAAI,GAAG,QAAQ,CAAA"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "libp2p",
3
- "version": "1.8.2",
3
+ "version": "1.8.3-0edbfe7af",
4
4
  "description": "JavaScript implementation of libp2p, a modular peer to peer network stack",
5
5
  "license": "Apache-2.0 OR MIT",
6
6
  "homepage": "https://github.com/libp2p/js-libp2p/tree/main/packages/libp2p#readme",
@@ -85,16 +85,16 @@
85
85
  "test:webkit": "aegir test -t browser -f \"./dist/test/**/*.spec.js\" -- --browser webkit"
86
86
  },
87
87
  "dependencies": {
88
- "@libp2p/crypto": "^4.1.7",
89
- "@libp2p/interface": "^1.6.2",
90
- "@libp2p/interface-internal": "^1.3.2",
91
- "@libp2p/logger": "^4.0.18",
92
- "@libp2p/multistream-select": "^5.1.15",
93
- "@libp2p/peer-collections": "^5.2.7",
94
- "@libp2p/peer-id": "^4.2.2",
95
- "@libp2p/peer-id-factory": "^4.2.2",
96
- "@libp2p/peer-store": "^10.1.3",
97
- "@libp2p/utils": "^5.4.7",
88
+ "@libp2p/crypto": "4.1.8-0edbfe7af",
89
+ "@libp2p/interface": "1.6.3-0edbfe7af",
90
+ "@libp2p/interface-internal": "1.3.3-0edbfe7af",
91
+ "@libp2p/logger": "4.0.19-0edbfe7af",
92
+ "@libp2p/multistream-select": "5.1.16-0edbfe7af",
93
+ "@libp2p/peer-collections": "5.2.8-0edbfe7af",
94
+ "@libp2p/peer-id": "4.2.3-0edbfe7af",
95
+ "@libp2p/peer-id-factory": "4.2.3-0edbfe7af",
96
+ "@libp2p/peer-store": "10.1.4-0edbfe7af",
97
+ "@libp2p/utils": "5.4.8-0edbfe7af",
98
98
  "@multiformats/dns": "^1.0.6",
99
99
  "@multiformats/multiaddr": "^12.2.3",
100
100
  "@multiformats/multiaddr-matcher": "^1.2.1",
@@ -113,15 +113,15 @@
113
113
  },
114
114
  "devDependencies": {
115
115
  "@chainsafe/libp2p-yamux": "^6.0.2",
116
- "@libp2p/circuit-relay-v2": "^1.1.3",
117
- "@libp2p/identify": "^2.1.3",
118
- "@libp2p/interface-compliance-tests": "^5.4.10",
119
- "@libp2p/mplex": "^10.1.3",
120
- "@libp2p/plaintext": "^1.1.3",
121
- "@libp2p/tcp": "^9.1.3",
122
- "@libp2p/websockets": "^8.1.3",
116
+ "@libp2p/circuit-relay-v2": "1.1.4-0edbfe7af",
117
+ "@libp2p/identify": "2.1.4-0edbfe7af",
118
+ "@libp2p/interface-compliance-tests": "5.4.11-0edbfe7af",
119
+ "@libp2p/mplex": "10.1.4-0edbfe7af",
120
+ "@libp2p/plaintext": "1.1.4-0edbfe7af",
121
+ "@libp2p/tcp": "9.1.4-0edbfe7af",
122
+ "@libp2p/websockets": "8.1.4-0edbfe7af",
123
123
  "@multiformats/mafmt": "^12.1.6",
124
- "aegir": "^43.0.1",
124
+ "aegir": "^44.0.1",
125
125
  "delay": "^6.0.0",
126
126
  "it-all": "^3.0.6",
127
127
  "it-drain": "^3.0.7",
package/src/get-peer.ts CHANGED
@@ -43,7 +43,7 @@ export function getPeerAddress (peer: PeerId | Multiaddr | Multiaddr[]): PeerAdd
43
43
  } else {
44
44
  const maPeerId = peerIdFromString(maPeerIdStr)
45
45
 
46
- if (peerId == null || !peerId.equals(maPeerId)) {
46
+ if (peerId?.equals(maPeerId) !== true) {
47
47
  throw new CodeError('Multiaddrs must all have the same peer id or have no peer id', codes.ERR_INVALID_PARAMETERS)
48
48
  }
49
49
  }
package/src/version.ts CHANGED
@@ -1,2 +1,2 @@
1
- export const version = '1.8.2'
1
+ export const version = '1.8.3-0edbfe7af'
2
2
  export const name = 'libp2p'
@@ -1,14 +0,0 @@
1
- {
2
- "Libp2pInit": "https://libp2p.github.io/js-libp2p/interfaces/libp2p.index.Libp2pInit.html",
3
- ".:Libp2pInit": "https://libp2p.github.io/js-libp2p/interfaces/libp2p.index.Libp2pInit.html",
4
- "Libp2pOptions": "https://libp2p.github.io/js-libp2p/types/libp2p.index.Libp2pOptions.html",
5
- ".:Libp2pOptions": "https://libp2p.github.io/js-libp2p/types/libp2p.index.Libp2pOptions.html",
6
- "ServiceFactoryMap": "https://libp2p.github.io/js-libp2p/types/libp2p.index.ServiceFactoryMap.html",
7
- ".:ServiceFactoryMap": "https://libp2p.github.io/js-libp2p/types/libp2p.index.ServiceFactoryMap.html",
8
- "createLibp2p": "https://libp2p.github.io/js-libp2p/functions/libp2p.index.createLibp2p.html",
9
- ".:createLibp2p": "https://libp2p.github.io/js-libp2p/functions/libp2p.index.createLibp2p.html",
10
- "name": "https://libp2p.github.io/js-libp2p/variables/libp2p.version.name.html",
11
- "./version:name": "https://libp2p.github.io/js-libp2p/variables/libp2p.version.name.html",
12
- "version": "https://libp2p.github.io/js-libp2p/variables/libp2p.version.version.html",
13
- "./version:version": "https://libp2p.github.io/js-libp2p/variables/libp2p.version.version.html"
14
- }