Changes on ruby arrays as parameters (#226)

This commit is contained in:
Ornithologist Coder 2017-05-09 14:14:33 +02:00 committed by wxcafé
parent 3ad0c4ab19
commit 87550bdc7c

View file

@ -74,8 +74,7 @@ ___
### Parameter types ### Parameter types
When an array parameter is mentioned, the Rails convention of specifying array parameters in query strings is meant. When an array parameter is mentioned, the Rails convention of specifying array parameters in query strings is meant.
For example, a ruby array like `foo = [1, 2, 3]` can be encoded in the params as `foo[]=1&foo[]=2&foo[]=3`. For example, a ruby array like `foo = [1, 2, 3]` should be encoded in the params as `foo[]=1&foo[]=2&foo[]=3`, with empty square brackets.
Square brackets can be indexed but can also be empty.
When a file parameter is mentioned, a form-encoded upload is expected. When a file parameter is mentioned, a form-encoded upload is expected.