mirror of
https://github.com/moodle/moodle.git
synced 2025-08-04 08:26:37 +02:00
blocklib: MDL-19010 eliminate remaining calls to blocks_repopulate_page
This commit is contained in:
parent
cf37931b7f
commit
6cbcbf0fb3
7 changed files with 15 additions and 17 deletions
|
@ -842,8 +842,7 @@ define('RESTORE_GROUPS_GROUPINGS', 3);
|
|||
if (empty($backup_block_format)) { // This is a backup from Moodle < 1.5
|
||||
if (empty($blockinfo)) {
|
||||
// Looks like it's from Moodle < 1.3. Let's give the course default blocks...
|
||||
$newpage = page_create_object(PAGE_COURSE_VIEW, $restore->course_id);
|
||||
blocks_repopulate_page($newpage);
|
||||
blocks_add_default_course_blocks($DB->get_record('course', array('id' => $restore->course_id)));
|
||||
} else {
|
||||
// We just have a blockinfo field, this is a legacy 1.4 or 1.3 backup
|
||||
$blockrecords = $DB->get_records('block', null, '', 'name, id');
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue