Skip to content

Commit

Permalink
DefaultResolveFn: Use case insensitive comparison
Browse files Browse the repository at this point in the history
  • Loading branch information
abihf authored Mar 24, 2018
1 parent 53935ab commit 0b39fb1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion executor.go
Original file line number Diff line number Diff line change
Expand Up @@ -851,7 +851,7 @@ func DefaultResolveFn(p ResolveParams) (interface{}, error) {
valueField := sourceVal.Field(i)
typeField := sourceVal.Type().Field(i)
// try matching the field name first
if typeField.Name == p.Info.FieldName {
if strings.EqualFold(typeField.Name, p.Info.FieldName) {
return valueField.Interface(), nil
}
tag := typeField.Tag
Expand Down

0 comments on commit 0b39fb1

Please sign in to comment.