From fdfd26645416b1744a5aa48ab70bf50b97ffc108 Mon Sep 17 00:00:00 2001 From: Jun Pataleta Date: Thu, 13 Jun 2019 18:20:21 +0800 Subject: [PATCH] MDL-65910 report_stats: Add stattype query condition for consistency --- report/stats/user.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/report/stats/user.php b/report/stats/user.php index ae71c4f8c20..7309a08adff 100644 --- a/report/stats/user.php +++ b/report/stats/user.php @@ -130,9 +130,11 @@ $param->table = 'user_'.$param->table; $wheres = [ "userid = :userid", "timeend >= :timeend", + "stattype = :stattype", ]; $params['userid'] = $user->id; $params['timeend'] = $param->timeafter; +$params['stattype'] = $param->stattype; // Add condition for course ID when specified. if ($course->id != SITEID) { $wheres[] = "courseid = :courseid";