This repository was archived by the owner on Nov 15, 2018. It is now read-only.
This repository was archived by the owner on Nov 15, 2018. It is now read-only.
Simple add on Lists failing in 1.1.0+ #48
Closed
Description
Working on 1.0.0, but failing on 1.1.0 and 1.2.0-preview1-22759
Here I'm attempting to add a new entry on List named Mylist which already has two entries (at indexes zero and one)
[{"op":"add","path":"/mylist/2","value":{"myname":"foo","age":33}}]
Response:
JsonPatchException: The index value provided by path segment '2' is out of bounds of the array size.
I'm guessing it's incorrectly looking at the length of the list prior to adding. With a dash at the end instead of the new index, this will work:
[{"op":"add","path":"/mylist/-","value":{"myname":"foo","age":33}}]