Skip to content

Commit

Permalink
fix: The calculated days are not accurate
Browse files Browse the repository at this point in the history
  • Loading branch information
simlecode committed Oct 9, 2022
1 parent d0634ee commit 69337d8
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions cmd/market-client/storage.go
Original file line number Diff line number Diff line change
Expand Up @@ -703,8 +703,9 @@ uiLoop:
continue
}

if days < int(MinDealDuration/builtin.EpochsInDay) {
printErr(fmt.Errorf("minimum duration is %d days", int(MinDealDuration/builtin.EpochsInDay)))
minDealDurationDays := uint64(MinDealDuration) / (builtin.SecondsInDay / BlockDelaySecs)
if days < int(minDealDurationDays) {
printErr(fmt.Errorf("minimum duration is %d days", minDealDurationDays))
continue
}

Expand Down

0 comments on commit 69337d8

Please sign in to comment.