فهرست منبع

Handle *interface{} and remove unnecessary type conversion

bits01 8 سال پیش
والد
کامیت
4339695112
1فایلهای تغییر یافته به همراه1 افزوده شده و 1 حذف شده
  1. 1 1
      redis/scan.go

+ 1 - 1
redis/scan.go

@@ -186,7 +186,7 @@ func convertAssign(d interface{}, s interface{}) (err error) {
 	case string:
 		switch d := d.(type) {
 		case *string:
-			*d = string(s)
+			*d = s
 		case *interface{}:
 			*d = s
 		case nil: