diff --git a/analytics/classes/local/indicator/community_of_inquiry_activity.php b/analytics/classes/local/indicator/community_of_inquiry_activity.php index 5deaeb6049e..555bb420e7c 100644 --- a/analytics/classes/local/indicator/community_of_inquiry_activity.php +++ b/analytics/classes/local/indicator/community_of_inquiry_activity.php @@ -836,7 +836,8 @@ abstract class community_of_inquiry_activity extends linear { // When the course is using format weeks we use the week's end date. $format = course_get_format($activity->get_modinfo()->get_course()); // We should change this in MDL-60702. - if (method_exists($format, 'get_section_dates')) { + if (get_class($format) == 'format_weeks' || is_subclass_of($format, 'format_weeks') + && method_exists($format, 'get_section_dates')) { $dates = $format->get_section_dates($section); // We need to consider the +2 hours added by get_section_dates.