From: Matthias Schmidt Date: Tue, 19 Aug 2014 17:11:09 +0000 (+0200) Subject: Improve default category permission implementation X-Git-Tag: 2.1.0_Alpha_1~426 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=4c6a3ef41b772dc7a652c361a02013e620be9bdc;p=GitHub%2FWoltLab%2FWCF.git Improve default category permission implementation --- diff --git a/wcfsetup/install/files/lib/data/category/Category.class.php b/wcfsetup/install/files/lib/data/category/Category.class.php index dd7db4e8d4..bf42a494c0 100644 --- a/wcfsetup/install/files/lib/data/category/Category.class.php +++ b/wcfsetup/install/files/lib/data/category/Category.class.php @@ -166,6 +166,10 @@ class Category extends ProcessibleDatabaseObject implements IPermissionObject, I return $this->getParentCategory()->getPermission($permission); } + if ($this->getObjectType()->defaultpermission !== null) { + return $this->getObjectType()->defaultpermission ? true : false; + } + return $this->defaultPermission; }