From d6c213835299336a3309bed8f3b1a970b1ebb1e2 Mon Sep 17 00:00:00 2001 From: Marcel Werk Date: Mon, 1 Sep 2014 18:28:13 +0200 Subject: [PATCH] Improved AbstractModerationQueueHandler implementation --- .../queue/AbstractModerationQueueHandler.class.php | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/wcfsetup/install/files/lib/system/moderation/queue/AbstractModerationQueueHandler.class.php b/wcfsetup/install/files/lib/system/moderation/queue/AbstractModerationQueueHandler.class.php index e42e02df43..23d8d41de7 100644 --- a/wcfsetup/install/files/lib/system/moderation/queue/AbstractModerationQueueHandler.class.php +++ b/wcfsetup/install/files/lib/system/moderation/queue/AbstractModerationQueueHandler.class.php @@ -38,6 +38,12 @@ abstract class AbstractModerationQueueHandler implements IModerationQueueHandler */ protected $objectType = ''; + /** + * required permission for assigned users + * @var string + */ + protected $requiredPermission = 'mod.general.canUseModeration'; + /** * @see \wcf\system\moderation\queue\IModerationQueueHandler::identifyOrphans() */ @@ -105,6 +111,6 @@ abstract class AbstractModerationQueueHandler implements IModerationQueueHandler */ public function isAffectedUser(ModerationQueue $queue, $userID) { $user = new UserProfile(new User($userID)); - return $user->getPermission('mod.general.canUseModeration'); + return $user->getPermission($this->requiredPermission); } } -- 2.20.1