Skip to content

Commit

Permalink
feat: reconcile OnChainDealID
Browse files Browse the repository at this point in the history
  • Loading branch information
Jason Cihelka committed May 30, 2023
1 parent f03a26d commit f0b3da7
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion core/delta-rpc.go
Original file line number Diff line number Diff line change
Expand Up @@ -399,7 +399,7 @@ type DealStats_Deal struct {
PropCid string `json:"propCid"`
DealUUID string `json:"dealUuid"`
Miner string `json:"miner"`
DealID int64 `json:"dealId"`
DealID uint `json:"dealId"`
Failed bool `json:"failed"`
Verified bool `json:"verified"`
Slashed bool `json:"slashed"`
Expand Down
2 changes: 2 additions & 0 deletions core/delta-watcher.go
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,7 @@ func computeReplicationUpdates(dealStats DealStatsResponse) []db.Replication {
if len(deal.Deals) > 0 {
r.ProposalCid = deal.Deals[0].PropCid
r.DealUUID = deal.Deals[0].DealUUID
r.OnChainDealID = deal.Deals[0].DealID
}
if len(deal.PieceCommitments) > 0 {
r.ContentCommP = deal.PieceCommitments[0].Piece
Expand All @@ -134,6 +135,7 @@ func computeReplicationUpdates(dealStats DealStatsResponse) []db.Replication {
if len(deal.Deals) > 0 {
r.ProposalCid = deal.Deals[0].PropCid
r.DealUUID = deal.Deals[0].DealUUID
r.OnChainDealID = deal.Deals[0].DealID
}
toUpdate = append(toUpdate, r)

Expand Down

0 comments on commit f0b3da7

Please sign in to comment.