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

Course created event is triggered too late

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 3.0
    • Fix Version/s: 3.0
    • Component/s: Course
    • Labels:

      Description

      Discovered while working on MDL-44640
      in funciton create_course() \core\events\course_created is triggered after we add blocks, enrolment instances, etc.

      This may be good for event observers but in the logs it will look like we first create enrolment instances for some course and THEN create a course itself.

      I had to adjust unit tests in MDL-44640 because the course_created event is no longer the first one in the sink after creating the course.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              marina Marina Glancy
              Reporter:
              marina Marina Glancy
              Peer reviewer:
              Ryan Wyllie Ryan Wyllie
              Integrator:
              David Monllaó David Monllaó
              Tester:
              John Okely John Okely
              Participants:
              Component watchers:
              Amaia Anabitarte, Carlos Escobedo, Ferran Recio, Ilya Tregubov, Sara Arjona (@sarjona)
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Fix Release Date:
                16/Nov/15