Skip to content
This repository has been archived by the owner on Jun 16, 2018. It is now read-only.

Patch which adds to a collection instantiates wrong type #15

Open
martypitt opened this issue Jan 4, 2015 · 0 comments
Open

Patch which adds to a collection instantiates wrong type #15

martypitt opened this issue Jan 4, 2015 · 0 comments

Comments

@martypitt
Copy link

(Possibly related to #14)

Given:

public class Project implements Serializable {
    @Id
    String id;

    List<Story> stories = Lists.newArrayList();
}

applying the following patch:

[{"op":"add","path":"/stories/0","value":{"id":"story1420381381217.764656"}}]

I expect that an instance of Story is created, and added to the stories list. Instead, an instance of Project is created, and added to the stories list (which will later result in a casting exception)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

No branches or pull requests

1 participant