Plagiarism API MDL-13680 move update_status call untill after print header so it...
authorDan Marsden <Dan@digitalclay.co.nz>
Thu, 14 Oct 2010 21:40:04 +0000 (21:40 +0000)
committerDan Marsden <Dan@digitalclay.co.nz>
Thu, 14 Oct 2010 21:40:04 +0000 (21:40 +0000)
mod/assignment/lib.php

index cee84af..88914d9 100644 (file)
@@ -1096,7 +1096,6 @@ class assignment_base {
                         self::FILTER_REQUIRE_GRADING => get_string('requiregrading', 'assignment'));
 
         $updatepref = optional_param('updatepref', 0, PARAM_INT);
-        plagiarism_update_status($this->course, $this->cm);
 
         if (isset($_POST['updatepref'])){
             $perpage = optional_param('perpage', 10, PARAM_INT);
@@ -1139,6 +1138,9 @@ class assignment_base {
 
         echo '<div class="usersubmissions">';
 
+        //hook to allow plagiarism plugins to update status/print links.
+        plagiarism_update_status($this->course, $this->cm);
+
         /// Print quickgrade form around the table
         if ($quickgrade) {
             $formattrs = array();