Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-64645

Deleting unconfirmed users in cleanup task creates invalid data requests when "Create automatic data deletion requests" setting is enabled

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Open
    • Priority: Minor
    • Resolution: Unresolved
    • Affects Version/s: 3.5.3
    • Fix Version/s: None
    • Component/s: Privacy
    • Labels:
      None
    • Affected Branches:
      MOODLE_35_STABLE

      Description

      When "Create automatic data deletion requests (tool_dataprivacy | automaticdeletionrequests)" setting is enabled, a new data request for the deleted user will be created from an observer listening for "user_deleted" event. This assumes the deleted user's record in mdl_user table presents, which is true in most cases.

      However if the deleted user is an unconfirmed user (clean up task using "Delete not fully setup users after" setting), the logic in "delete_unconfirmed_users_task" is:

       - call delete_user() function, which triggers the "user_deleted" event, thus create a data request.

       - then delete user's record from mdl_user table.

      This will end up with a data request on a record in mdl_user table that doesn't exist. When site administrators try to access the data request page, they will see a "Invalid user" error.

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              weilai Lai Wei
              Participants:
              Component watchers:
              Andrew Nicols, Mathew May, Michael Hawkins, Shamim Rezaie, Simey Lameze
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated: