Commit 7c3c43e2 authored by Vincent Petry's avatar Vincent Petry Committed by GitHub
Browse files

Merge pull request #26559 from IljaN/master

Username autocomplete option in admin menu now also toggles autocomp…
parents 52f19721 861011cc
......@@ -212,7 +212,11 @@ if (isset($_POST['action']) && isset($_POST['itemType']) && isset($_POST['itemSo
$result = [];
if (isset($_GET['search'])) {
$cm = OC::$server->getContactsManager();
if (!is_null($cm) && $cm->isEnabled()) {
$userEnumerationAllowed = OC::$server->getConfig()
->getAppValue('core', 'shareapi_allow_share_dialog_user_enumeration', 'no') == 'yes';
if (!is_null($cm) && $cm->isEnabled() && $userEnumerationAllowed) {
$contacts = $cm->search((string)$_GET['search'], ['FN', 'EMAIL']);
foreach ($contacts as $contact) {
if (!isset($contact['EMAIL'])) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment