diff --git a/library/Icinga/Authentication/UserGroup/LdapUserGroupBackend.php b/library/Icinga/Authentication/UserGroup/LdapUserGroupBackend.php index 2c366338a..122453990 100644 --- a/library/Icinga/Authentication/UserGroup/LdapUserGroupBackend.php +++ b/library/Icinga/Authentication/UserGroup/LdapUserGroupBackend.php @@ -397,20 +397,6 @@ class LdapUserGroupBackend extends LdapRepository implements UserGroupBackendInt return $this->ambiguousMemberAttribute; } - /** - * Return a new query for the given columns - * - * @param array $columns The desired columns, if null all columns will be queried - * - * @return RepositoryQuery - */ - public function select(array $columns = null) - { - $query = parent::select($columns); - $query->getQuery()->setBase($this->groupBaseDn); - return $query; - } - /** * Initialize this repository's virtual tables * @@ -575,8 +561,11 @@ class LdapUserGroupBackend extends LdapRepository implements UserGroupBackendInt */ public function requireTable($table, RepositoryQuery $query = null) { - if ($query !== null && $table === 'group' && $this->groupFilter) { - $query->getQuery()->setNativeFilter($this->groupFilter); + if ($query !== null) { + $query->getQuery()->setBase($this->groupBaseDn); + if ($table === 'group' && $this->groupFilter) { + $query->getQuery()->setNativeFilter($this->groupFilter); + } } return parent::requireTable($table, $query);