Fixing convert uuid.UUID => uuid.UUID

This commit is contained in:
Alex 2020-02-19 21:24:48 +01:00
parent bf847e845e
commit dea7cb49b0

View File

@ -84,7 +84,11 @@ func Сonvert(from interface{}, kind string, to interface{}) {
switch f.Type.String() { switch f.Type.String() {
case "uuid.UUID": case "uuid.UUID":
mv := fv.Interface().(uuid.UUID) mv := fv.Interface().(uuid.UUID)
ft.SetString(mv.String()) if ft.Type().String() == "uuid.UUID" {
ft.Set(fv)
} else {
ft.SetString(mv.String())
}
default: default:
ft.Set(fv) ft.Set(fv)
} }