Skip to content
This repository has been archived by the owner on Jan 8, 2020. It is now read-only.

Bug in Zend\Stdlib\PriorityList->valid() #6881

Closed
ha-sash opened this issue Nov 16, 2014 · 1 comment
Closed

Bug in Zend\Stdlib\PriorityList->valid() #6881

ha-sash opened this issue Nov 16, 2014 · 1 comment
Assignees
Milestone

Comments

@ha-sash
Copy link

ha-sash commented Nov 16, 2014

Mistake in logic of check of the current value.
If the item contains FALSE that PriorityList->valid () will return FALSE.

    // foreach behaves incorrectly
    public function valid()
    {
        return ($this->current() !== false);
    }
    //foreach behaves correctly
    public function valid()
    {
        return (current($this->items) !== false);
    }
@samsonasik
Copy link
Contributor

duplicate with #6768 , please close this.

@ha-sash ha-sash closed this as completed Nov 16, 2014
@Ocramius Ocramius self-assigned this Nov 20, 2014
@Ocramius Ocramius added this to the 2.3.4 milestone Nov 20, 2014
Ocramius added a commit that referenced this issue Nov 20, 2014
…'develop'

Close #6773
Close #6768
Close #6820
Close #6834
Close #6881
Forward port #6773
Forward port #6768
Ocramius added a commit that referenced this issue Nov 20, 2014
# for free to subscribe to this conversation on GitHub. Already have an account? #.
Projects
None yet
Development

No branches or pull requests

3 participants