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

Delay applying new state to currentCollection #19

Merged
merged 1 commit into from
Mar 3, 2017

Conversation

danielrhammond
Copy link
Contributor

Since state was being immediately applied to CollectionViewModelDataSource's currentCollection it would result in observers of CollectionViewModelDataSource to get the post-update sections if they queried during .willUpdateItems, this is a pretty bad breach of that api contract but thankfully diff endine has its own copy of the sections so wasn't effected.

Since state was being immediately applied to CollectionViewModelDataSource's currentCollection it would result in observers of CollectionViewModelDataSource to get the post-update sections if they queried during `.willUpdateItems`, this is a pretty bad breach of that api contract but thankfully diff endine has its own copy of the sections so wasn't effected.
@danielrhammond
Copy link
Contributor Author

Wanted to write some tests for this but it got super messy fast due to collection view model datasource's interaction with {NS,UI}CollectionView.

Here's my first take at it, want to spend some more time trying to come up with a better solution but want to separate that from landing this fix.

@wkiefer wkiefer merged commit e8e5519 into master Mar 3, 2017
@wkiefer wkiefer deleted the danielh/fix-collection-view-model-datasource branch March 3, 2017 04:12
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

Successfully merging this pull request may close these issues.

None yet

2 participants