public static function delete_data_for_all_users_in_context_course_module(string $component, \context $context) {
        global $DB;

        if ($context instanceof \context_module) {
            // Delete course completion data for this context.
            \core_completion\privacy\provider::delete_completion(null, null, $context->instanceid);
        }
    }
public static function delete_data_for_all_users_in_context_course_module(string $component, \context $context) {
        global $DB;

        if ($context instanceof \context_module) {
            // Delete course completion data for this context.
            \core_completion\privacy\provider::delete_completion(null, null, $context->instanceid);
        }
    }
public static function delete_data_for_all_users_in_context_course_module ( string $ component , \ context $ context ) { global $ DB ; if ( $ context instanceof \ context_module ) { // Delete course completion data for this context. \ core_completion \ privacy \ provider :: delete_completion ( null , null , $ context -> instanceid ) ; } }
Handle removal of 'standard' data for course modules.

This will handle deletion for things such as activity completion.

@param   string              $component The component being deleted for.
@param   \context            $context The context to delete all data for.
Handle removal of standard data for course modules .