Merge branch 'MDL-69973_310' of https://github.com/stronk7/moodle into MOODLE_310_STABLE
authorSara Arjona <sara@moodle.com>
Mon, 2 Nov 2020 14:44:54 +0000 (15:44 +0100)
committerSara Arjona <sara@moodle.com>
Mon, 2 Nov 2020 14:44:54 +0000 (15:44 +0100)
badges/backpack-add.php
mod/lti/openid-configuration.php

index 2e2478b..1ff7795 100644 (file)
@@ -98,7 +98,7 @@ if (!empty($issuedbadge->recipient->id)) {
                 $assertionid
             );
 
-            if (!$assertionentityid && strpos($sitebackpack->backpackapiurl, 'badgr')) {
+            if ($assertionentityid && strpos($sitebackpack->backpackapiurl, 'badgr')) {
                 $assertionentityid = badges_generate_badgr_open_url(
                     $sitebackpack,
                     OPEN_BADGES_V2_TYPE_ASSERTION,
index e30b121..6de875d 100644 (file)
@@ -41,13 +41,14 @@ $conf = [
     'token_endpoint_auth_methods_supported' => ['private_key_jwt'],
     'token_endpoint_auth_signing_alg_values_supported' => ['RS256'],
     'jwks_uri' => (new moodle_url('/mod/lti/certs.php'))->out(false),
+    'authorization_endpoint' => (new moodle_url('/mod/lti/auth.php'))->out(false),
     'registration_endpoint' => (new moodle_url('/mod/lti/openid-registration.php'))->out(false),
     'scopes_supported' => $scopes,
     'response_types_supported' => ['id_token'],
     'subject_types_supported' => ['public', 'pairwise'],
     'id_token_signing_alg_values_supported' => ['RS256'],
     'claims_supported' => ['sub', 'iss', 'name', 'given_name', 'family_name', 'email'],
-    'https://purl.imsglobal.org/spec/lti-platform-configuration ' => [
+    'https://purl.imsglobal.org/spec/lti-platform-configuration' => [
         'product_family_code' => 'moodle',
         'version' => $CFG->release,
         'messages_supported' => ['LtiResourceLink', 'LtiDeepLinkingRequest'],