From 8a2d713f6841a93c206e65e6cba68ab22be23744 Mon Sep 17 00:00:00 2001 From: achingbrain Date: Mon, 4 May 2020 13:52:35 +0100 Subject: [PATCH 1/4] chore: swap ipfs-block for ipld-block The module was rename and the renamed version is not compatible with the old version so here we update it. These are only dev deps so not a breaking change. --- package.json | 4 ++-- test/block-service-test.js | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/package.json b/package.json index 42dc121..4b54755 100644 --- a/package.json +++ b/package.json @@ -37,8 +37,8 @@ "cids": "^0.8.0", "dirty-chai": "^2.0.1", "fs-extra": "^9.0.0", - "ipfs-block": "~0.8.1", - "ipfs-repo": "^1.0.1", + "ipfs-repo": "^2.0.0", + "ipld-block": "^0.9.1", "lodash": "^4.17.11", "multihashing-async": "^0.8.1" }, diff --git a/test/block-service-test.js b/test/block-service-test.js index 3f16bba..93480e0 100644 --- a/test/block-service-test.js +++ b/test/block-service-test.js @@ -5,7 +5,7 @@ const chai = require('chai') chai.use(require('dirty-chai')) const expect = chai.expect -const Block = require('ipfs-block') +const Block = require('ipld-block') const _ = require('lodash') const { collect } = require('streaming-iterables') const CID = require('cids') From 2a80002055932457ea541eda0e60a9ec3e921c4f Mon Sep 17 00:00:00 2001 From: achingbrain Date: Mon, 4 May 2020 14:06:51 +0100 Subject: [PATCH 2/4] feat: add deleteMany method Similar to the putMany and getMany methods, deleteMany allows passing streams of CIDs into the module. --- README.md | 25 ++++++++++++++----------- package.json | 2 +- src/index.js | 28 +++++++++++++++++++++++++--- test/block-service-test.js | 23 +++++++++++++++++++++++ 4 files changed, 63 insertions(+), 15 deletions(-) diff --git a/README.md b/README.md index 5de876f..7f29389 100644 --- a/README.md +++ b/README.md @@ -31,16 +31,19 @@ ## Table of Contents -- [Install](#install) - - [npm](#npm) -- [Usage](#usage) - - [Node.js](#nodejs) - - [Example](#example) - - [Browser: Browserify, Webpack, other bundlers](#browser-browserify-webpack-other-bundlers) - - [Browser: `