Note: You are currently viewing documentation for Moodle 4.0. Up-to-date documentation for the latest stable version of Moodle may be available here: error/moodle/invalidcoursemodule.

error/moodle/invalidcoursemodule

From MoodleDocs

The ID for the course module is invalid. Please contact the site admin.

For some unknown reason, this happens sometimes when deleting a user. Clicking the back button of the browser and deleting the user again, makes the deleting process continue and delete the user.

It can also happen when "Legacy course files" is enabled. Disabling this can solve the issue.