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

Forum summary report date filtering throws an exception

XMLWordPrintable

    • 1
    • HQ 2023 Sprint I4.1 Moppies

      When accessing a forum summary report with some entries, after applying the "Dates" filter, the report throws an exception

      Exception - core_user::get_fullname(): Argument #1 ($user) must be of type stdClass, int given, called in [dirroot]/lib/moodlelib.php on line 3653
      

      Stack trace:
      * line 1293 of /lib/classes/user.php: TypeError thrown
      * line 3653 of /lib/moodlelib.php: call to core_user::get_fullname()
      * line 366 of /mod/forum/report/summary/classes/summary_table.php: call to fullname()
      * line 861 of /lib/tablelib.php: call to forumreport_summary\summary_table->col_export()
      * line 2087 of /lib/tablelib.php: call to flexible_table->format_row()
      * line 685 of /mod/forum/report/summary/classes/summary_table.php: call to table_sql->build_table()
      * line 64 of /mod/forum/report/summary/renderer.php: call to forumreport_summary\summary_table->out()
      * line 193 of /mod/forum/report/summary/index.php: call to forumreport_summary_renderer->render_summary_table()
      

      The problem comes from mod/forum/report/summary/classes/summary_table.php:354 where $data is incorrectly overridden.

      This problem existed in previous versions, but only returned an empty string instead the user's full name, but this recent change is causing the exception now.

      Thanks a lot pholden for the help investigating it.

            mikelmartíncorrales Mikel Martín Corrales
            mikelmartíncorrales Mikel Martín Corrales
            Paul Holden Paul Holden
            Mathew May Mathew May
            Ron Carl Alfon Yu Ron Carl Alfon Yu
            Votes:
            0 Vote for this issue
            Watchers:
            10 Start watching this issue

              Created:
              Updated:
              Resolved:

                Estimated:
                Original Estimate - 0 minutes
                0m
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 2 hours, 12 minutes
                2h 12m

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