jsonapi icon indicating copy to clipboard operation
jsonapi copied to clipboard

Multiple values for same filter

Open CostantiniMatteo opened this issue 5 years ago • 2 comments

The jsonapi spec states that multiple filter values can be combined in a comma-separated list. For example:

GET /comments?filter[post]=1,2 HTTP/1.1

However, I noticed that the library returns a string "1,2" instead of splitting it and returning ["1", "2"].

Is this by design, and therefore such cases needs to be handled manually by splitting the string? I would be happy to implement it, if the change is welcome.

Thank you!

CostantiniMatteo avatar Sep 04 '20 13:09 CostantiniMatteo

Definitely a welcome change.

jherdman avatar Sep 04 '20 13:09 jherdman