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

Need to deal with merging in has_many relations that are initialized to an empty collection. #13

Open
malomalo opened this issue Jun 2, 2013 · 0 comments

Comments

@malomalo
Copy link
Owner

malomalo commented Jun 2, 2013

The Listing#index.json in MLS doesn't return photos.

These photos get initialized to an empty array when a new model is created.

When Backbone.Collection merges models together it creates an empty array and will overwrite a collection full of data retrieved from Listing#show.

Either we shouldn't initialize the array (maybe lazily initialize a collection on Model.get). Or mark so that when merging in it's discarded. Not sure on the best approach.

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