MDL-15175: fix sync with external Oracle database merged from 1.9

This commit is contained in:
jerome 2008-08-13 06:41:46 +00:00
parent d5b5dfaf4f
commit 1ed6ae073d

View File

@ -175,6 +175,7 @@ class auth_plugin_db extends auth_plugin_base {
if ($rs = $authdb->Execute($sql)) {
if ( !$rs->EOF ) {
$fields_obj = $rs->FetchObj();
$fields_obj = (object)array_change_key_case((array)$fields_obj , CASE_LOWER);
foreach ($selectfields as $localname=>$externalname) {
$result[$localname] = $textlib->convert($fields_obj->{$localname}, $this->config->extencoding, 'utf-8');
}
@ -419,7 +420,7 @@ class auth_plugin_db extends auth_plugin_base {
print_error('auth_dbcantconnect','auth');
} else if ( !$rs->EOF ) {
while ($rec = $rs->FetchRow()) {
array_push($result, $rec->username);
array_push($result, $rec->USERNAME);
}
}