MDL-8733 fixed approving logic when editing; merged from MOODLE_16_STABLE

This commit is contained in:
skodak
2007-03-03 12:25:40 +00:00
parent bf18b2aa09
commit b6057d4afa
+2 -3
View File
@@ -151,9 +151,8 @@
/// All student edits are marked unapproved by default
$record = get_record('data_records','id',$rid);
if ($data->approval == 1 || has_capability('mod/data:approve', $context)) {
$record->approved = 1;
} else {
/// reset approved flag after student edit
if (!has_capability('mod/data:approve', $context)) {
$record->approved = 0;
}