Skip to content

Commit

Permalink
fix: types in example
Browse files Browse the repository at this point in the history
  • Loading branch information
Alan Shaw authored Jul 22, 2021
1 parent 5ac2e36 commit 1662d85
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/client/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,10 @@ const fileInput = document.querySelector('input[type="file"]')
const rootCid = await client.put(fileInput.files) // Promise<CIDString>

// Get info on the Filecoin deals that the CID is stored in
const info = await client.status(rootCid) // Promise<Metadata>
const info = await client.status(rootCid) // Promise<Status | undefined>

// Fetch and verify files from web3.storage
const res = await client.get(rootCid) // Promise<Web3Response>
const res = await client.get(rootCid) // Promise<Web3Response | null>
const files = await res.files() // Promise<Web3File[]>
for (const file of files) {
console.log(`${file.cid} ${file.name} ${file.size}`)
Expand Down

0 comments on commit 1662d85

Please sign in to comment.