From: toyomoyo Date: Thu, 26 Jul 2007 02:47:44 +0000 (+0000) Subject: merged fix for MDL-10564, wrong userid used in get_my_courses() for blogs X-Git-Url: http://git.mjollnir.org/gw?a=commitdiff_plain;h=6872debcc8ab99468820ef66b2258284e8b25110;p=moodle.git merged fix for MDL-10564, wrong userid used in get_my_courses() for blogs --- diff --git a/blog/lib.php b/blog/lib.php index b5a3d8162f..1bfc95f65d 100755 --- a/blog/lib.php +++ b/blog/lib.php @@ -433,7 +433,7 @@ break; case BLOG_COURSE_LEVEL: - $mycourses = array_keys(get_my_courses($targetuserid)); + $mycourses = array_keys(get_my_courses($USER->id)); $usercourses = array_keys(get_my_courses($targetuserid)); $shared = array_intersect($mycourses, $usercourses); if (!empty($shared)) { @@ -443,7 +443,7 @@ break; case BLOG_GROUP_LEVEL: - $mycourses = array_keys(get_my_courses($targetuserid)); + $mycourses = array_keys(get_my_courses($USER->id)); $usercourses = array_keys(get_my_courses($targetuserid)); $shared = array_intersect($mycourses, $usercourses); foreach ($shared as $courseid) {