Please sign in to comment.
internal/jsonutil: Skip unexported fields.
This change makes jsonutil.UnmarshalGraphQL not consider unexported fields when looking for a matching field. This is done because such fields cannot be unmarshaled into, and it's more consistent with behavior of package encoding/json. Document unmarshalValue precondition that v must be addressing and not obtained by the use of unexported fields. That would make it settable, which is a requirement for the needs of unmarshalValue. We arrange the internal jsonutil code so that unmarshalValue is never called on an unsettable reflect.Value. Fixes #36.
- Loading branch information...
Showing with 22 additions and 6 deletions.