Skip to content

Commit 5cd703a

Browse files
authored
chore: upgrade ipld-raw (#3113)
Resolve now throws if the path is not '/'.
1 parent d102dfd commit 5cd703a

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@
5151
"ipld-block": "^0.9.1",
5252
"ipld-dag-cbor": "^0.15.2",
5353
"ipld-dag-pb": "^0.18.5",
54-
"ipld-raw": "^4.0.1",
54+
"ipld-raw": "^5.0.0",
5555
"iso-url": "^0.4.7",
5656
"it-tar": "^1.2.2",
5757
"it-to-buffer": "^1.0.0",

src/dag/get.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,10 @@ module.exports = configure((api, options) => {
3232
)
3333
}
3434

35+
if (block.cid.codec === 'raw' && !resolved.remPath) {
36+
resolved.remPath = '/'
37+
}
38+
3539
return dagResolver.resolve(block.data, resolved.remPath)
3640
}
3741
})

0 commit comments

Comments
 (0)