Browse Source

Don't parse margin if we have it as a number already

debug-collab-settlement
Thomas Eizinger 3 years ago
parent
commit
024ded6eb4
No known key found for this signature in database GPG Key ID: 651AC83A6C6C8B96
  1. 2
      taker-frontend/src/components/Trade.tsx

2
taker-frontend/src/components/Trade.tsx

@ -107,7 +107,7 @@ export default function Trade({
const parse = (val: any) => Number.parseInt(val.replace(/^\$/, ""));
const balanceTooLow = walletBalance && walletBalance < parse(margin);
const balanceTooLow = walletBalance && walletBalance < marginAsNumber;
const quantityTooHigh = maxQuantity < parse(quantity);
const quantityTooLow = minQuantity > parse(quantity);
const quantityGreaterZero = parse(quantity) > 0;

Loading…
Cancel
Save