Merge branch 'MDL-45650_master' of https://github.com/markn86/moodle
authorSam Hemelryk <sam@moodle.com>
Mon, 26 May 2014 01:59:08 +0000 (13:59 +1200)
committerSam Hemelryk <sam@moodle.com>
Mon, 26 May 2014 01:59:08 +0000 (13:59 +1200)
1  2 
user/view.php

diff --cc user/view.php
@@@ -190,10 -190,9 +190,10 @@@ if ($user->deleted) 
  // OK, security out the way, now we are showing the user.
  // Trigger a user profile viewed event.
  $event = \core\event\user_profile_viewed::create(array(
-     'objectid' => $USER->id,
+     'objectid' => $user->id,
      'relateduserid' => $user->id,
 -    'context' => $usercontext,
 +    'courseid' => $course->id,
 +    'context' => $coursecontext,
      'other' => array(
          'courseid' => $course->id,
          'courseshortname' => $course->shortname,