Skip to content
This repository was archived by the owner on Oct 16, 2020. It is now read-only.

Commit 2d31686

Browse files
fsdiogoolizilla
authored andcommitted
fix: ipfs connection test (#18)
`ipfs.get` is not consistently available across `js-ipfs` and `js-ipfs-api`. Use `ipfs.files.get` for compatability.
1 parent d42ec33 commit 2d31686

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Diff for: src/index.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ const defaultOptions = {
1717
defaultApiAddress: '/ip4/127.0.0.1/tcp/5001',
1818
ipfsConnectionTest: (ipfs) => {
1919
// ipfs connection is working if can we fetch the empty directtory.
20-
return ipfs.get('QmUNLLsPACCz1vLxQVkXqqLX5R1X345qqfHbsf67hvA3Nn')
20+
return ipfs.files.get('QmUNLLsPACCz1vLxQVkXqqLX5R1X345qqfHbsf67hvA3Nn')
2121
}
2222
}
2323

0 commit comments

Comments
 (0)