Clone
Randall Hauch
committed
on 15 Feb 13
MODE-1816 REST v2 responses base property representations on number of values
The response should base the field value for a given property … Show more
MODE-1816 REST v2 responses base property representations on number of values

The response should base the field value for a given property based upon

whether that JCR property is single-valued or multi-valued, not upon

the number of values. If multi-valued, then the field value should be

an array (even if there is just one item). Version 1 of the REST API

already works this way, but the version 2 was changed.

Note that it is still possible for property representations in

requests to use a single value (rather than an array) when setting

a multi-value to a single value, or the more conventional practice

of using an array to set a multi-valued array. The latter is obviously

required when setting the mutli-valued property to 0 or 2+ values.

Several of the expected results were incorrect and have been changed.

Show less

master + 12 more