You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If a user wants to remove a to-one relationship a PATCH should be done on the /resource/:resourceId/relationships/relatedResource, with a body containing the following:
But, when err := jsonapi.UnmarshalPayload(c.Request.Body, data) is executed, an error is given with the following message "data is not a jsonapi representation of '*chronos.RelatedResource'". What should I do to allow null values on jsonapi representations?
The text was updated successfully, but these errors were encountered:
@brunoluiz Did you ever find a solution for this? A different library? It looks like a PR to make this work was added in 2017 but in 2018 work was added which introduces the error.
I can't remember, but I guess I didn't find a solution after all. Nowadays,
I always end-up using GraphQL for public APIs, so I haven't used this
package anymore.
If a user wants to remove a to-one relationship a PATCH should be done on the /resource/:resourceId/relationships/relatedResource, with a body containing the following:
(http://jsonapi.org/format/#crud-updating-to-one-relationships)
But, when
err := jsonapi.UnmarshalPayload(c.Request.Body, data)
is executed, an error is given with the following message"data is not a jsonapi representation of '*chronos.RelatedResource'"
. What should I do to allownull
values on jsonapi representations?The text was updated successfully, but these errors were encountered: