From 78a00990b67d4735811c827dea68d95b3e09dbb0 Mon Sep 17 00:00:00 2001 From: Ankit Agarwal Date: Thu, 11 Oct 2012 10:55:37 +0800 Subject: [PATCH] MDL-31010 comments: setup_course should update if passed courseid is different from the cached one --- comment/locallib.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/comment/locallib.php b/comment/locallib.php index fd62b619347..af88c37b150 100644 --- a/comment/locallib.php +++ b/comment/locallib.php @@ -89,7 +89,7 @@ class comment_manager { */ private function setup_course($courseid) { global $PAGE, $DB; - if (!empty($this->course)) { + if (!empty($this->course) && $this->course->id == $courseid) { // already set, stop return; }