mirror of
https://github.com/redis/go-redis.git
synced 2025-04-17 20:17:02 +03:00
fix(appendArg): appendArg case special type (#2489)
Signed-off-by: monkey92t <golang@88.com>
This commit is contained in:
parent
540554043b
commit
38aa0b7792
@ -2,8 +2,10 @@ package redis
|
||||
|
||||
import (
|
||||
"context"
|
||||
"encoding"
|
||||
"errors"
|
||||
"io"
|
||||
"net"
|
||||
"reflect"
|
||||
"strings"
|
||||
"time"
|
||||
@ -75,6 +77,8 @@ func appendArg(dst []interface{}, arg interface{}) []interface{} {
|
||||
dst = append(dst, k, v)
|
||||
}
|
||||
return dst
|
||||
case time.Time, time.Duration, encoding.BinaryMarshaler, net.IP:
|
||||
return append(dst, arg)
|
||||
default:
|
||||
// scan struct field
|
||||
v := reflect.ValueOf(arg)
|
||||
|
Loading…
x
Reference in New Issue
Block a user