Skip to content

Conversation

@davgothic
Copy link
Contributor

The current implementation of the Iterator interface will stop looping over the activityData array as soon as a null value is found due to the following method:

public function valid()
{
    return (bool) $this->current();
}

I have replaced the implementation of the Iterator interface with the more suited IteratorAggregate.

@tbarbugli
Copy link
Member

using the IteratorAggregate interface is indeed a much better approach. thank you for your contribution!

tbarbugli added a commit that referenced this pull request Apr 29, 2015
Fixed broken Iterator interface implementation in EnrichedActivity class
@tbarbugli tbarbugli merged commit ea47444 into GetStream:master Apr 29, 2015
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.

2 participants