Skip to content

Validate all include options - #370

Merged
shishirmk merged 2 commits into
Netflix:devfrom
danielduke:validate-all-include-options
Apr 7, 2019
Merged

Validate all include options#370
shishirmk merged 2 commits into
Netflix:devfrom
danielduke:validate-all-include-options

Conversation

@danielduke

Copy link
Copy Markdown

Per the spec, https://jsonapi.org/format/#fetching-includes

If a server is unable to identify a relationship path or does not support inclusion of resources from a path, it MUST respond with 400 Bad Request.

Currently the library is only checking the first instance due to using detect which stops processing after the block returns true once.

Without this change, the new test in spec/lib/object_serializer_spec.rb:145 fails.

@danielduke danielduke closed this Jan 4, 2019
@danielduke danielduke reopened this Jan 4, 2019
@danielduke danielduke closed this Jan 4, 2019
@danielduke danielduke reopened this Jan 4, 2019
@danielduke danielduke mentioned this pull request Jan 4, 2019
@danielduke danielduke closed this Jan 4, 2019
@danielduke danielduke reopened this Jan 4, 2019
@danielduke danielduke closed this Jan 7, 2019
@danielduke danielduke reopened this Jan 7, 2019
@danielduke
danielduke changed the base branch from dev to master January 7, 2019 21:46
@danielduke
danielduke changed the base branch from master to dev January 7, 2019 21:50
@shishirmk
shishirmk merged commit 9f0608d into Netflix:dev Apr 7, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants