MDL-58188 mod_label: fixed call to update_completion_date_event()

Part of MDL-55611 epic.
This commit is contained in:
Mark Nelson 2017-03-24 12:47:31 +08:00 committed by Dan Poltawski
parent 8d4e0f29dc
commit de036a2d76

View File

@ -111,7 +111,7 @@ function label_delete_instance($id) {
$result = true;
$cm = get_coursemodule_from_instance('label', $id);
\core_completion\api::update_completion_date_event('label', $label->id, null);
\core_completion\api::update_completion_date_event($cm->id, 'label', $label->id, null);
if (! $DB->delete_records("label", array("id"=>$label->id))) {
$result = false;