Skip to content

Commit

Permalink
Comment out ipfs storing of proof and commit
Browse files Browse the repository at this point in the history
  • Loading branch information
stephhuynh18 committed Dec 13, 2023
1 parent cff4bf8 commit 56dce1e
Showing 1 changed file with 20 additions and 18 deletions.
38 changes: 20 additions & 18 deletions src/services/anchor-service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -497,24 +497,26 @@ export class AnchorService {
cid: anchorCid,
}

try {
await this.ipfsService.storeRecord(ipfsAnchorCommit)
logger.debug(
`Stored anchor commit for ${candidate.cid} of stream ${candidate.streamId} on IPFS`
)
await this.ipfsService.publishAnchorCommit(anchorCid, candidate.streamId)
logger.debug(
`Created anchor commit with CID ${anchorCid.toString()} for stream ${candidate.streamId.toString()}`
)
return anchor
} catch (err) {
const msg = `Error publishing anchor commit of commit ${
candidate.cid
} for stream ${candidate.streamId.toString()}: ${err}`
logger.err(msg)
Metrics.count(METRIC_NAMES.ERROR_IPFS, 1)
return anchor
}
return anchor

// try {
// await this.ipfsService.storeRecord(ipfsAnchorCommit)
// logger.debug(
// `Stored anchor commit for ${candidate.cid} of stream ${candidate.streamId} on IPFS`
// )
// await this.ipfsService.publishAnchorCommit(anchorCid, candidate.streamId)
// logger.debug(
// `Created anchor commit with CID ${anchorCid.toString()} for stream ${candidate.streamId.toString()}`
// )
// return anchor
// } catch (err) {
// const msg = `Error publishing anchor commit of commit ${
// candidate.cid
// } for stream ${candidate.streamId.toString()}: ${err}`
// logger.err(msg)
// Metrics.count(METRIC_NAMES.ERROR_IPFS, 1)
// return anchor
// }
}

/**
Expand Down

0 comments on commit 56dce1e

Please sign in to comment.