Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Incorrect mapping for multiple objects mapped to same relationtype #136

Open
mindbogglegames opened this issue Nov 7, 2018 · 0 comments

Comments

@mindbogglegames
Copy link

mindbogglegames commented Nov 7, 2018

I have set up the following composition for the Person model

Person.compose(Skill, 'likes_skill', 'LIKES');
Person.compose(Perk, 'likes_perk', 'LIKES');

In the neo4j database the person has a relation of 'LIKES' to a 'Skill'

When I fetch the Person via (read or where) it maps the specific 'Skill' to a 'Perk' instead so I incorrectly get this object
{ "likes_perk": [ "programming" ] }
when what I would expect is
{ "likes_skill": [ "programming" ] }
I assume this has something to both compositions mapping to the same relation? But I would assume the Seraph model would check the type also before mapping to it "likes_skill" or "likes_perk"

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

No branches or pull requests

1 participant