MDL-34363 gradebook Adding check to prevent incorrect override when a blank feedback...
authorEric Merrill <merrill@oakland.edu>
Tue, 21 Aug 2012 04:24:55 +0000 (00:24 -0400)
committerEric Merrill <merrill@oakland.edu>
Tue, 21 Aug 2012 04:24:55 +0000 (00:24 -0400)
grade/report/grader/lib.php

index 3f6681e..70eb9b2 100644 (file)
@@ -225,7 +225,7 @@ class grade_report_grader extends grade_report {
                 $changedgrades = true;
 
             } else if ($datatype === 'feedback') {
-                if ($oldvalue->feedback === $postedvalue) {
+                if (($oldvalue->feedback === $postedvalue) or ($oldvalue->feedback === NULL and empty($postedvalue))) {
                     continue;
                 }
             }