Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-60567

Competency - list_competencies external API

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Minor Minor
    • 3.3.4, 3.4.1
    • 3.2.3, 3.3.3, 3.4, 3.5
    • Competencies

      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

       

            damyon Damyon Wiese
            khangvo Khang Vo
            Mark Nelson Mark Nelson
            Eloy Lafuente (stronk7) Eloy Lafuente (stronk7)
            CiBoT CiBoT
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved:

                Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.