Merge pull request #1536 from c9s/edwin/okx/print-more-msg

MINOR: [okx] print more logs
This commit is contained in:
bailantaotao 2024-02-20 18:45:13 +08:00 committed by GitHub
commit 9dead2edd9
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 2 additions and 2 deletions

View File

@ -214,7 +214,7 @@ func (e *Exchange) SubmitOrder(ctx context.Context, order types.SubmitOrder) (*t
// set price field for limit orders
switch order.Type {
case types.OrderTypeStopLimit, types.OrderTypeLimit:
case types.OrderTypeStopLimit, types.OrderTypeLimit, types.OrderTypeLimitMaker:
orderReq.Price(order.Market.FormatPrice(order.Price))
case types.OrderTypeMarket:
// Because our order.Quantity unit is base coin, so we indicate the target currency to Base.

View File

@ -256,5 +256,5 @@ func (a APIResponse) Validate() error {
}
func (a APIResponse) Error() error {
return fmt.Errorf("retCode: %s, retMsg: %s", a.Code, a.Message)
return fmt.Errorf("retCode: %s, retMsg: %s, data: %s", a.Code, a.Message, string(a.Data))
}