public function getCurrent()
    {
        if ($this->current === null) {
            $this->current = false;

            $item = $this->getFromSession();
            if (!$item) {
                $item = $this->getFromCookie();
            }

            if ($item && $this->checkAccessCurrent($item)) {
                $this->beforeSetCurrent($item);
                $this->setAndSaveCurrent($item);
            } else {
                $this->setCurrent($this->getCurrentDefault());
            }
        }

        return $this->current;
    }