MDL-61708 mod_lti: use fullnamedisplay to pass lis_person_name_full
authorwillem <willem@Infolearn-Dev1.fritz.box>
Fri, 23 Mar 2018 12:07:36 +0000 (13:07 +0100)
committerwillem <willem@Infolearn-Dev1.fritz.box>
Fri, 23 Mar 2018 12:07:36 +0000 (13:07 +0100)
Students 'firstname lastname' was passed to LTI Provider as
lis_person_name_full. Now changed to use fullnamedisplay.

mod/lti/locallib.php

index 3bf73d3..9976ce6 100644 (file)
@@ -450,7 +450,7 @@ function lti_build_request($instance, $typeconfig, $course, $typeid = null, $isl
     ) {
         $requestparams['lis_person_name_given'] = $USER->firstname;
         $requestparams['lis_person_name_family'] = $USER->lastname;
-        $requestparams['lis_person_name_full'] = $USER->firstname . ' ' . $USER->lastname;
+        $requestparams['lis_person_name_full'] = fullname($USER);
         $requestparams['ext_user_username'] = $USER->username;
     }