mirror of
https://github.com/moodle/moodle.git
synced 2025-01-19 06:18:28 +01:00
MDL-34460 - remove uncessary context retrival
spotted during review
This commit is contained in:
parent
957a8d48fc
commit
bc8db7649b
@ -451,7 +451,7 @@ function user_get_user_details($user, $course = null, array $userfields = array(
|
||||
$coursecontext = context_course::instance($mycourse->id);
|
||||
$enrolledcourse = array();
|
||||
$enrolledcourse['id'] = $mycourse->id;
|
||||
$enrolledcourse['fullname'] = format_string($mycourse->fullname, true, array('context' => context_course::instance($mycourse->id)));
|
||||
$enrolledcourse['fullname'] = format_string($mycourse->fullname, true, array('context' => $coursecontext)));
|
||||
$enrolledcourse['shortname'] = format_string($mycourse->shortname, true, array('context' => $coursecontext));
|
||||
$enrolledcourses[] = $enrolledcourse;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user