MDL-22051, move comments deletion code to accesslib.php
This commit is contained in:
@@ -1923,6 +1923,8 @@ function delete_context($contextlevel, $instanceid) {
|
||||
|
||||
blocks_delete_all_for_context($context->id);
|
||||
filter_delete_all_for_context($context->id);
|
||||
require_once($CFG->dirroot . '/comment/lib.php');
|
||||
comment::delete_comments(array('contextid'=>$context->id));
|
||||
}
|
||||
|
||||
return true;
|
||||
|
||||
Reference in New Issue
Block a user