You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
BREAKING CHANGE: repo.blocks.query() now returns multihashes as a key
instead of CID. If you want to have CID returned call it as query({},
true), which will constructs CIDv1 using IPLD's RAW codec. This means
that this constructed CID might not equal to the one that the block was originally
saved. Related to ipfs/js-ipfs#2415
Copy file name to clipboardExpand all lines: README.md
+19Lines changed: 19 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -197,6 +197,25 @@ Get block.
197
197
198
198
*`cid` is the content id of [type CID](https://github.com/ipld/js-cid#readme).
199
199
200
+
#### `Promise<boolean> repo.blocks.has (obj)`
201
+
202
+
Indicate if block is present
203
+
204
+
*`obj` is either the content id of [type CID](https://github.com/ipld/js-cid#readme) or [multihash](https://github.com/multiformats/js-multihashing).
205
+
206
+
#### `Promise<boolean> repo.blocks.delete (obj)`
207
+
208
+
Deletes
209
+
210
+
*`obj` is either the content id of [type CID](https://github.com/ipld/js-cid#readme) or [multihash](https://github.com/multiformats/js-multihashing).
0 commit comments