7
0

feat: added handler to convert an error slice to string slice

Esse commit está contido em:
PacoDw 2019-10-23 14:16:23 -05:00
commit 2e0cffc044

Ver arquivo

@ -1131,6 +1131,11 @@ func ToStringSliceE(i interface{}) ([]string, error) {
return v, nil
case string:
return strings.Fields(v), nil
case []error:
for _, err := range i.([]error) {
a = append(a, err.Error())
}
return a, nil
case interface{}:
str, err := ToStringE(v)
if err != nil {