diff --git a/src/index.ts b/src/index.ts index 480fc53..ea19f42 100644 --- a/src/index.ts +++ b/src/index.ts @@ -35,14 +35,14 @@ export async function fetchIpfs( path = "", receiveUpdate: DataFn ) { - if (!ipfsPath(`/ipfs/{${hash}`)) { + if (!ipfsPath(`/ipfs/${hash}`)) { throw new Error("Invalid hash"); } return doFetch("fetchIpfs", { hash, path }, receiveUpdate); } export async function statIpfs(hash: string, path = "") { - if (!ipfsPath(`/ipfs/{${hash}`)) { + if (!ipfsPath(`/ipfs/${hash}`)) { throw new Error("Invalid hash"); } return doFetch("statIpfs", { hash, path });