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
{{ message }}
This repository has been archived by the owner on Feb 12, 2023. It is now read-only.
Which means that the 'pin to remote service' functions like pinTokenData will fail with TypeError: CID instance expected instead of object.
As far as I can tell, the way to fix this is to use the CID classes that come with the multiformats dependency in ipfs-http-client
such as...
const { CID } = require('multiformats/cid')
and then update the extractCID helper method to use the multiformats CID.parse method...
function extractCID(cidOrURI) {
// remove the ipfs:// prefix, split on '/' and return first path component (root CID)
const cidString = stripIpfsUriPrefix(cidOrURI).split('/')[0]
return CID.parse(cidString)
}
The text was updated successfully, but these errors were encountered:
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
The latest version of
ipfs-http-client
client is using CIDs from https://www.npmjs.com/package/multiformats but Minty is currently configured to use CIDS from https://www.npmjs.com/package/cidsWhich means that the 'pin to remote service' functions like
pinTokenData
will fail with TypeError: CID instance expected instead of object.As far as I can tell, the way to fix this is to use the CID classes that come with the multiformats dependency in
ipfs-http-client
such as...
const { CID } = require('multiformats/cid')
and then update the
extractCID
helper method to use the multiformats CID.parse method...The text was updated successfully, but these errors were encountered: