Skip to content

Commit

Permalink
cowordersigner: don't hardcode validDuration to support limit orders
Browse files Browse the repository at this point in the history
  • Loading branch information
jfschwarz committed May 2, 2024
1 parent 97e3b28 commit 0463cec
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ export default {
(response) => response.json()
)

const validDuration = 60 * 30 // 30 minutes
const validDuration = order.validTo - Math.floor(Date.now() / 1000)
const feeAmountBP = Math.ceil(
(parseInt(order.feeAmount) / parseInt(order.sellAmount)) * 10000
)
Expand Down

0 comments on commit 0463cec

Please sign in to comment.