/** * Check - role is unremovable or not * * @param \XLite\Model\Role $role Role * * @return boolean */ protected function isUnremovableRole(\XLite\Model\Role $role) { return $role->isPermanentRole() || \XLite\Core\Auth::getInstance()->getProfile()->GetRoles()->contains($role); }
/** * {@inheritDoc} */ public function isPermanentRole() { $this->__initializer__ && $this->__initializer__->__invoke($this, 'isPermanentRole', array()); return parent::isPermanentRole(); }