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

New event for eventhandler: user_login

XMLWordPrintable

    • Icon: Improvement Improvement
    • Resolution: Duplicate
    • Icon: Minor Minor
    • None
    • 2.0.4, 2.1.1
    • Authentication
    • MOODLE_20_STABLE, MOODLE_21_STABLE

      I would like to create an additional piece of code which is executed asynchronously whenever an user logs in.
      I want to be able to send the username of this user to a different system.
      But I don't want to edit the auth plugins which are provided by default.

      So what I'm asking for is the possibility to trigger user_login at/around the return of authenticate_user_login in /lib/moodlelib.php.
      My basic idea would be to add:
      events_trigger('user_login', $user);
      just before the
      return $user;

            moodle.com Moodle HQ
            sebsoft Sebastian Berm
            Votes:
            2 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved:

                Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.