fix: cid is a CID instance already

This commit is contained in:
Derrick Hammer 2023-09-11 14:01:31 -04:00
parent eeb8e35bf9
commit 5227acb287
Signed by: pcfreak30
GPG Key ID: C997C339BE476FF2
1 changed files with 2 additions and 2 deletions

View File

@ -107,7 +107,7 @@ maybeInitDefaultPortals();
const fd = await fs.open(file as string);
let cid;
let cid: CID;
try {
cid = await uploadObject(
@ -178,7 +178,7 @@ await peerDefer.promise;
let newEntry;
try {
newEntry = CID.decode(cid).toRegistryEntry();
newEntry = cid.toRegistryEntry();
} catch (e) {
console.error("Failed to publish: ", e.message);
process.exit();