From: Matthias Schmidt Date: Fri, 29 Jul 2016 17:33:42 +0000 (+0200) Subject: Only show ban clipboard action for non-banned users X-Git-Tag: 3.0.0_Beta_1~898 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=58aa56d68f5e5cd30c1448b58a643b8d212c84df;p=GitHub%2FWoltLab%2FWCF.git Only show ban clipboard action for non-banned users --- diff --git a/wcfsetup/install/files/lib/system/clipboard/action/UserClipboardAction.class.php b/wcfsetup/install/files/lib/system/clipboard/action/UserClipboardAction.class.php index 32725f05f0..ace1cf20ed 100644 --- a/wcfsetup/install/files/lib/system/clipboard/action/UserClipboardAction.class.php +++ b/wcfsetup/install/files/lib/system/clipboard/action/UserClipboardAction.class.php @@ -109,7 +109,14 @@ class UserClipboardAction extends AbstractClipboardAction { return []; } - return $this->__validateAccessibleGroups(array_keys($this->objects)); + $userIDs = []; + foreach ($this->objects as $user) { + if (!$user->banned) { + $userIDs[] = $user->userID; + } + } + + return $this->__validateAccessibleGroups($userIDs); } /**