There is an bug while Administrator deletes a course.
moodle/lib/moodlelib.php: line 3012
else {
notify('Function', $moddelete() . 'doesn\'t exist!');
$result = false;
}
This ''notify'' line makes a bug. ''$moddelete'' is one of the function in some modules.
However if there is no such a function that name $moddelete it goes ''else'' block that shown above.
As you can see, in ''notify'' function we call the $moddelete function. However as I say, this else block is
used when $moddelete function isn't existed.
Therefore, it makes crash the course deleting process and stop.
So user cannot delete any course when they use one of the modules that doen't have $moddelete functions(exactly $modname.'_delete_instance).
Thus, the parenthesis next to ''$moddelete'' have to be removed and the code would be changed like that
else {
notify('Function', $moddelete. 'doesn\'t exist!');
$result = false;
}
Thank you.