Skip to content
This repository has been archived by the owner on Mar 11, 2021. It is now read-only.

Enum.ConvertFromModel should use Basetype.ConvertFromModel method #2224

Merged
merged 14 commits into from
Oct 9, 2018
Merged
2 changes: 1 addition & 1 deletion workitem/enum_type.go
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ func containsAll(a []interface{}, v []interface{}) bool {
}

func (t EnumType) ConvertFromModel(value interface{}) (interface{}, error) {
converted, err := t.BaseType.ConvertToModel(value)
converted, err := t.BaseType.ConvertFromModel(value)
if err != nil {
return nil, fmt.Errorf("error converting enum value: %s", err.Error())
}
Expand Down