Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

MDL-38369 repository: Remove output before redirect

  • Loading branch information...
commit 2d1fd9e2445cae8e0c6d3e6325ffe837794c86ec 1 parent 5e00b9a
@FMCorz FMCorz authored
Showing with 3 additions and 3 deletions.
  1. +3 −3 repository/manage_instances.php
View
6 repository/manage_instances.php
@@ -142,7 +142,6 @@
/// Display page header
$PAGE->set_title($title);
$PAGE->set_heading($fullname);
-echo $OUTPUT->header();
if ($context->contextlevel == CONTEXT_USER) {
if ( !$course = $DB->get_record('course', array('id'=>$usercourseid))) {
@@ -196,13 +195,13 @@
}
if ($success) {
$savedstr = get_string('configsaved', 'repository');
- echo $OUTPUT->heading($savedstr);
redirect($baseurl);
} else {
print_error('instancenotsaved', 'repository', $baseurl);
}
exit;
} else { // Display the form
+ echo $OUTPUT->header();
echo $OUTPUT->heading(get_string('configplugin', 'repository_'.$plugin));
$OUTPUT->box_start();
$mform->display();
@@ -224,18 +223,19 @@
}
if ($instance->delete()) {
$deletedstr = get_string('instancedeleted', 'repository');
- echo $OUTPUT->heading($deletedstr);
redirect($baseurl, $deletedstr, 3);
} else {
print_error('instancenotdeleted', 'repository', $baseurl);
}
exit;
}
+ echo $OUTPUT->header();
$formcontinue = new single_button(new moodle_url($baseurl, array('delete' => $delete, 'sure' => 'yes')), get_string('yes'));
$formcancel = new single_button($baseurl, get_string('no'));
echo $OUTPUT->confirm(get_string('confirmdelete', 'repository', $instance->name), $formcontinue, $formcancel);
$return = false;
} else {
+ echo $OUTPUT->header();
repository::display_instances_list($context);
$return = false;
}
Please sign in to comment.
Something went wrong with that request. Please try again.