]> source.dussan.org Git - nextcloud-server.git/commitdiff
fix: Only list remnants as disabled if option is enabled 45347/head
authorCôme Chilliet <come.chilliet@nextcloud.com>
Thu, 16 May 2024 08:58:28 +0000 (10:58 +0200)
committerCôme Chilliet <come.chilliet@nextcloud.com>
Thu, 6 Jun 2024 14:48:27 +0000 (16:48 +0200)
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
apps/user_ldap/lib/User_Proxy.php

index afa4a1941822eda92eb8e0540e08c1e08a5b82c1..df9e025f871a486c5913f4a2c9547840e187807f 100644 (file)
@@ -440,6 +440,9 @@ class User_Proxy extends Proxy implements IUserBackend, UserInterface, IUserLDAP
        }
 
        public function getDisabledUserList(?int $limit = null, int $offset = 0, string $search = ''): array {
+               if ((int)$this->getAccess(array_key_first($this->backends) ?? '')->connection->markRemnantsAsDisabled !== 1) {
+                       return [];
+               }
                $disabledUsers = $this->deletedUsersIndex->getUsers();
                if ($search !== '') {
                        $disabledUsers = array_filter(