SF Bug #2885907 - samba domain sid blank

This commit is contained in:
Deon George 2009-11-21 11:04:37 +11:00
parent b1139658bf
commit d4483f961f
2 changed files with 9 additions and 8 deletions

View File

@ -266,8 +266,6 @@ class TemplateRender extends PageRender {
*/
case 'MultiList':
case 'PickList':
$args[2] = strtolower($args[2]);
# arg5 overrides our container
if (empty($args[5]))
$container = $server->getContainerPath($container,$args[0]);

View File

@ -2882,11 +2882,12 @@ function return_ldap_hash($base,$filter,$key,$attrs,$sort=true) {
if (is_array($values[$key]))
foreach ($values[$key] as $i => $k)
foreach ($attrs as $attr) {
if (isset($values[$attr])) {
$lattr = strtolower($attr);
if (isset($values[$lattr])) {
$v = '';
if (is_array($values[$attr]) && isset($values[$attr][$i]))
$v = $values[$attr][$i];
if (is_array($values[$lattr]) && isset($values[$lattr][$i]))
$v = $values[$lattr][$i];
if (is_string($v) && (strlen($v) > 0))
$results[$k][$attr] = $v;
@ -2894,9 +2895,11 @@ function return_ldap_hash($base,$filter,$key,$attrs,$sort=true) {
}
else
foreach ($attrs as $attr)
if (isset($values[$attr]))
$results[$values[$key]][$attr] = $values[$attr];
foreach ($attrs as $attr) {
$lattr = strtolower($attr);
if (isset($values[$lattr]))
$results[$values[$key]][$attr] = $values[$lattr];
}
return $results;
}