X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=gosa-core%2Finclude%2Fclass_filterLDAP.inc;h=7697462049580281c7976e3314516cdeafd5e74f;hb=64d37db515e042b6152d69ba77362ab7ec6eada8;hp=d49463ae6aee9331b47e6b512224ac53ae1e599f;hpb=099fb791bb6d2c03127ac3d547d1540a456218e1;p=gosa.git diff --git a/gosa-core/include/class_filterLDAP.inc b/gosa-core/include/class_filterLDAP.inc index d49463ae6..769746204 100644 --- a/gosa-core/include/class_filterLDAP.inc +++ b/gosa-core/include/class_filterLDAP.inc @@ -2,29 +2,17 @@ class filterLDAP { - static function query($base, $scope, $filter, $attributes, $category, $method,$objectStorage= "") + static function query($base, $scope, $filter, $attributes, $category, $objectStorage= "") { $config= session::global_get('config'); $ldap= $config->get_ldap_link(TRUE); $flag= ($scope == "sub")?GL_SUBSEARCH:0; - $result= filterLDAP::get_list($base, $filter, $attributes, $category, $objectStorage,$method, $flag | GL_SIZELIMIT); + $result= filterLDAP::get_list($base, $filter, $attributes, $category, $objectStorage, $flag | GL_SIZELIMIT); return $result; } - - static function unifyResults($results) - { - $res = array(); - foreach($results as $entry){ - if(!isset($res[$entry['dn']])){ - $res[$entry['dn']] = $entry; - } - } - return(array_values($res)); - } - - static function get_list($base, $filter, $attributes, $category, $objectStorage, $method, $flags= GL_SUBSEARCH) + static function get_list($base, $filter, $attributes, $category, $objectStorage, $flags= GL_SUBSEARCH) { $ui= session::global_get('ui'); $config= session::global_get('config'); @@ -36,9 +24,7 @@ class filterLDAP { if (!is_array($objectStorage)) { $objectStorage= array($objectStorage); } - if(empty($method)){ - $method= (empty($objectStorage) && !($flags & GL_SUBSEARCH))?"ls":"search"; - } + $method= (empty($objectStorage) && !($flags & GL_SUBSEARCH))?"ls":"search"; // Initialize search bases $bases= array();