Closed Quintasan closed 3 years ago
It is expected. "Params" types intend to work with rack params, they can encode ruby arrays when names are passed as user_id[]=1&user_id[]=2
. In your case, I'd build a custom constructor type that coerces data to the expected output. Changing params type to support custom encoding doesn't look justified FWIW.
Describe the bug
When using a
params
schema, if you specify a key that has to be an Array then it doesn't get coerced unless it's a Ruby array.To Reproduce
Expected behavior
I would expect strings like "1,2,3,4" or "[1,2,3,4]" to be coerced into an Array instead, the actual format supported is to be discussed but the current behavior effectively performs no coercion.
My environment