From: Marcel Werk Date: Tue, 19 Aug 2014 14:40:26 +0000 (+0200) Subject: Added fallback return value X-Git-Tag: 2.1.0_Alpha_1~430 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=99c00b137f5b704b0081337e8bb23531fbbc4ff3;p=GitHub%2FWoltLab%2FWCF.git Added fallback return value --- diff --git a/wcfsetup/install/files/lib/data/category/Category.class.php b/wcfsetup/install/files/lib/data/category/Category.class.php index 42cc6b3447..dd7db4e8d4 100644 --- a/wcfsetup/install/files/lib/data/category/Category.class.php +++ b/wcfsetup/install/files/lib/data/category/Category.class.php @@ -43,6 +43,12 @@ class Category extends ProcessibleDatabaseObject implements IPermissionObject, I */ protected $permissions = null; + /** + * fallback return value used in Category::getPermission() + * @var boolean + */ + protected $defaultPermission = false; + /** * @see \wcf\data\DatabaseObject::$databaseTableIndexName */ @@ -160,7 +166,7 @@ class Category extends ProcessibleDatabaseObject implements IPermissionObject, I return $this->getParentCategory()->getPermission($permission); } - return false; + return $this->defaultPermission; } /**