webservice MDL-22255 fix moodle_user_get_users_by_id() ws function when no custom field are returned
This commit is contained in:
@@ -354,7 +354,7 @@ class moodle_user_external extends external_api {
|
||||
|
||||
$userarray = (array) $user; //we want to return an array not an object
|
||||
/// now we transfert all profile_field_xxx into the customfields external_multiple_structure required by description
|
||||
$userarray['customfields'] = null;
|
||||
$userarray['customfields'] = array();
|
||||
$customfields = profile_user_record($user->id);
|
||||
$customfields = (array) $customfields;
|
||||
foreach ($customfields as $key => $value) {
|
||||
|
||||
Reference in New Issue
Block a user