Pinq\Iterators\Standard\CoalesceIterator::doFetch PHP Method

doFetch() protected method

protected doFetch ( )
    protected function doFetch()
    {
        if ($element = $this->iterator->fetch()) {
            $this->isEmpty = false;
            return $element;
        } elseif ($this->isEmpty) {
            $this->isEmpty = false;
            return [$this->defaultKey, &$this->defaultValue];
        }
    }