updated LDAP filter for new base modules

This commit is contained in:
Roland Gruber 2005-01-10 10:57:04 +00:00
parent e0b36f32f5
commit e278195766
1 changed files with 4 additions and 6 deletions

View File

@ -88,13 +88,11 @@ function get_ldap_filter($scope) {
$filters = array(); $filters = array();
$orFilter = ''; $orFilter = '';
for ($i = 0; $i < sizeof($mods); $i++) { for ($i = 0; $i < sizeof($mods); $i++) {
if (is_base_module($mods[$i], $scope)) {
$module = new $mods[$i]($scope); $module = new $mods[$i]($scope);
$modinfo = $module->get_ldap_filter(); $modinfo = $module->get_ldap_filter();
if (isset($modinfo['or'])) $filters['or'][] = $modinfo['or']; if (isset($modinfo['or'])) $filters['or'][] = $modinfo['or'];
if (isset($modinfo['and'])) $filters['and'][] = $modinfo['and']; if (isset($modinfo['and'])) $filters['and'][] = $modinfo['and'];
} }
}
// build OR filter // build OR filter
if (sizeof($filters['or']) == 1) { if (sizeof($filters['or']) == 1) {
$orFilter = $filters['or'][0]; $orFilter = $filters['or'][0];