* @return boolean
*/
public function canDisable() {
- if (WCF::getSession()->getPermission('admin.content.cms.canManagePage') && !$this->originIsSystem && !$this->isLandingPage) {
+ if (WCF::getSession()->getPermission('admin.content.cms.canManagePage') && (!$this->originIsSystem || $this->pageType != 'system') && !$this->isLandingPage) {
return true;
}
* @return boolean false if the page should be hidden from menus
*/
public function isVisible() {
+ if ($this->isDisabled) return false;
if (!$this->validateOptions()) return false;
if (!$this->validatePermissions()) return false;
throw new IllegalLinkException();
}
+ if ($this->page->isDisabled && !WCF::getSession()->getPermission('admin.content.cms.canManagePage')) {
+ throw new IllegalLinkException();
+ }
+
$this->content = $this->page->getPageContentByLanguage($this->languageID);
if (empty($this->content)) {
throw new IllegalLinkException();