httpContext = $httpContext; $this->_registration = $registration; $this->_customerUrl = $customerUrl; } /** * @return string */ public function getHref() { return $this->_customerUrl->getRegisterUrl(); } /** * {@inheritdoc} */ protected function _toHtml() { if (!$this->_registration->isAllowed() || $this->httpContext->getValue(Context::CONTEXT_AUTH) ) { return ''; } return parent::_toHtml(); } }