-
Bug
-
Resolution: Fixed
-
Minor
-
3.2.3, 3.3.3, 3.4, 3.5
-
MOODLE_32_STABLE, MOODLE_33_STABLE, MOODLE_34_STABLE, MOODLE_35_STABLE
-
MOODLE_33_STABLE, MOODLE_34_STABLE
-
MDL-60567-master -
Inside the method:
public static function list_competencies($filters, $sort, $order, $skip, $limit) {
Line 843, the code uses:
foreach ($params['filters'] as $filter) {
if (!in_array($filter->column, $validcolumns)) {
throw new invalid_parameter_exception('Filter column was invalid');
}
$safefilters[$filter->column] = $filter->value;
}
But, according to the list_competencies_parameters, the $filter is an array, not an sdclass, so when I call the external API, the $filter->column and $filter-> value returns null, where $filter["column"] and $filter["value"] returns correct value.
The correct way should be using an array