Skip to content

Commit

Permalink
client/core: market orders are immediate (PreOrder)
Browse files Browse the repository at this point in the history
  • Loading branch information
chappjc committed Dec 29, 2022
1 parent 3ddf67a commit 92239af
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion client/core/bot.go
Original file line number Diff line number Diff line change
Expand Up @@ -1229,7 +1229,7 @@ func (c *Core) feeEstimates(form *TradeForm) (swapFees, redeemFees uint64, err e
LotSize: swapLotSize,
Lots: lots,
MaxFeeRate: fromAsset.MaxFeeRate,
Immediate: (form.IsLimit && form.TifNow),
Immediate: (form.IsLimit && form.TifNow) || !form.IsLimit,
FeeSuggestion: swapFeeSuggestion,
SelectedOptions: form.Options,
RedeemVersion: toWallet.version,
Expand Down
2 changes: 1 addition & 1 deletion client/core/core.go
Original file line number Diff line number Diff line change
Expand Up @@ -5107,7 +5107,7 @@ func (c *Core) PreOrder(form *TradeForm) (*OrderEstimate, error) {
LotSize: swapLotSize,
Lots: lots,
MaxFeeRate: assetConfigs.fromAsset.MaxFeeRate,
Immediate: form.IsLimit && form.TifNow,
Immediate: (form.IsLimit && form.TifNow) || !form.IsLimit,
FeeSuggestion: swapFeeSuggestion,
SelectedOptions: form.Options,
RedeemVersion: assetConfigs.toAsset.Version,
Expand Down

0 comments on commit 92239af

Please sign in to comment.