Skip to content

Commit

Permalink
MDL-48969 block_quiz_results: correct upgrade logic check
Browse files Browse the repository at this point in the history
  • Loading branch information
danpoltawski committed Mar 25, 2015
1 parent e961016 commit b74bff0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion blocks/quiz_results/db/upgrade.php
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ function xmldb_block_quiz_results_upgrade($oldversion, $block) {

if ($oldversion < 2015022200) {
// Only migrate if the block_activity_results is installed.
if (!check_dir_exists($CFG->dirroot . '/blocks/activity_results', false)) {
if (is_dir($CFG->dirroot . '/blocks/activity_results')) {

// Migrate all instances of block_quiz_results to block_activity_results.
$records = $DB->get_records('block_instances', array('blockname' => 'quiz_results'));
Expand Down

0 comments on commit b74bff0

Please sign in to comment.