From: Damyon Wiese Date: Tue, 30 Apr 2013 04:26:47 +0000 (+0800) Subject: Merge branch 'MDL-37966' of git://github.com/jonof/moodle X-Git-Tag: v2.5.0-rc1~157 X-Git-Url: http://git.moodle.org/gw?p=moodle.git;a=commitdiff_plain;h=767421c36c13552cadcaced08fcb657d76197682;hp=4969053f2522d6a27573ad8e6a7c6171057938d0 Merge branch 'MDL-37966' of git://github.com/jonof/moodle --- diff --git a/mod/assign/upgradelib.php b/mod/assign/upgradelib.php index 9415f47cdf1..e3899dda2fb 100644 --- a/mod/assign/upgradelib.php +++ b/mod/assign/upgradelib.php @@ -405,7 +405,7 @@ class assign_upgrade_manager { return false; } - $newcm->section = course_add_cm_to_section($newcm->course, $newcm->id, $section->section); + $newcm->section = course_add_cm_to_section($newcm->course, $newcm->id, $section->section, $cm->id); // Make sure visibility is set correctly (in particular in calendar). // Note: Allow them to set it even without moodle/course:activityvisibility.