From d4398bbbf9268611e9d89685976ddae0cc807cc8 Mon Sep 17 00:00:00 2001 From: c9s Date: Mon, 19 Sep 2022 13:07:56 +0800 Subject: [PATCH] bbgo: add more simple slice types to FilterSimpleArgs --- pkg/bbgo/order_executor_general.go | 2 +- pkg/util/simple_args.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pkg/bbgo/order_executor_general.go b/pkg/bbgo/order_executor_general.go index 91eabedbf..7cca499cf 100644 --- a/pkg/bbgo/order_executor_general.go +++ b/pkg/bbgo/order_executor_general.go @@ -361,7 +361,7 @@ func (e *GeneralOrderExecutor) ClosePosition(ctx context.Context, percentage fix tagStr := strings.Join(tags, ",") submitOrder.Tag = tagStr - Notify("closing %s position %s with tags: %v", e.symbol, percentage.Percentage(), tagStr) + Notify("Closing %s position %s with tags: %v", e.symbol, percentage.Percentage(), tagStr) _, err := e.SubmitOrders(ctx, *submitOrder) return err diff --git a/pkg/util/simple_args.go b/pkg/util/simple_args.go index bef39d9e0..e71b8ca9c 100644 --- a/pkg/util/simple_args.go +++ b/pkg/util/simple_args.go @@ -12,7 +12,7 @@ import ( func FilterSimpleArgs(args []interface{}) (simpleArgs []interface{}) { for _, arg := range args { switch arg.(type) { - case int, int64, int32, uint64, uint32, string, []byte, float64, float32, fixedpoint.Value, time.Time: + case int, int64, int32, uint64, uint32, string, []string, []byte, float64, []float64, float32, fixedpoint.Value, time.Time: simpleArgs = append(simpleArgs, arg) default: rt := reflect.TypeOf(arg)