From: Jan Schneider Date: Tue, 2 Mar 2010 18:17:42 +0000 (+0100) Subject: Don't retrieve user list if we don't display it anyway. X-Git-Url: https://git.internetallee.de/?a=commitdiff_plain;h=b893f69c5fc4c74c77ee9cba809192e82700975b;p=horde.git Don't retrieve user list if we don't display it anyway. --- diff --git a/horde/services/shares/edit.php b/horde/services/shares/edit.php index a05bc7b36..0fa50b968 100644 --- a/horde/services/shares/edit.php +++ b/horde/services/shares/edit.php @@ -261,7 +261,9 @@ if (is_a($share, 'PEAR_Error')) { $title = sprintf(_("Edit permissions for \"%s\""), $share->get('name')); } -if ($auth->hasCapability('list')) { +if ($auth->hasCapability('list') && + ($conf['auth']['list_users'] == 'list' || + $conf['auth']['list_users'] == 'both')) { $userList = $auth->listUsers(); if ($userList instanceof PEAR_Error) { Horde::logMessage($userList, __FILE__, __LINE__, PEAR_LOG_ERR); diff --git a/kronolith/perms.php b/kronolith/perms.php index aa95bd347..0914b3f29 100644 --- a/kronolith/perms.php +++ b/kronolith/perms.php @@ -270,7 +270,9 @@ if ($share instanceof PEAR_Error) { $title = sprintf(_("Edit Permissions for %s"), $share->get('name')); } -if ($auth->hasCapability('list')) { +if ($auth->hasCapability('list') && + ($conf['auth']['list_users'] == 'list' || + $conf['auth']['list_users'] == 'both')) { try { $userList = $auth->listUsers(); } catch (Exception $e) {