Skip to content

Commit

Permalink
Fix using EduAppCenter
Browse files Browse the repository at this point in the history
  • Loading branch information
csev committed Jul 27, 2018
1 parent fce1af5 commit edf3600
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 8 deletions.
2 changes: 1 addition & 1 deletion lti/store/route.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
require_once $CFG->dirroot."/admin/admin_util.php";

$local_path = route_get_local_path(__DIR__);
if ( $local_path == "canvas-config.xml" ) {
if ( strpos($local_path, "canvas-config.xml") === 0 ) {
require_once("canvas-config-xml.php");
return;
}
Expand Down
12 changes: 5 additions & 7 deletions vendor/tsugi/lib/src/Util/ContentItem.php
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ public function addLtiLinkItemExtended($params = array())
if (empty($params['activityId']))
$params['activityId'] = false;
if (empty($params['placementTarget']))
$params['placementTarget'] = 'window';
$params['placementTarget'] = 'iframe';
if (empty($params['placementWindowTarget']))
$params['placementWindowTarget'] = '';
if (empty($params['placementWidth']))
Expand All @@ -187,8 +187,7 @@ public function addLtiLinkItemExtended($params = array())
"text" : "For more information on how to build and host powerful LTI-based Tools quickly, see www.tsugi.org",
"url" : "http://www.tsugi.org/",
"placementAdvice" : {
"presentationDocumentTarget" : "window",
"windowTarget" : "_blank"
"presentationDocumentTarget" : "iframe"
},
"icon" : {
"@id" : "https://www.dr-chuck.net/tsugi-static/img/default-icon.png",
Expand Down Expand Up @@ -290,9 +289,9 @@ public function addContentItemExtended($params = array())
if (empty($params['fa_icon']))
$params['fa_icon'] = false;
if (empty($params['placementTarget']))
$params['placementTarget'] = 'window';
$params['placementTarget'] = 'iframe';
if (empty($params['placementWindowTarget']))
$params['placementWindowTarget'] = '_blank';
$params['placementWindowTarget'] = '';
if (empty($params['placementWidth']))
$params['placementWidth'] = '';
if (empty($params['placementHeight']))
Expand All @@ -305,8 +304,7 @@ public function addContentItemExtended($params = array())
"text" : "For more information on how to build and host powerful LTI-based Tools quickly, see www.tsugi.org",
"url" : "http://www.tsugi.org/",
"placementAdvice" : {
"presentationDocumentTarget" : "window",
"windowTarget" : "_blank"
"presentationDocumentTarget" : "iframe"
},
"icon" : {
"@id" : "https://www.dr-chuck.net/tsugi-static/img/default-icon.png",
Expand Down

0 comments on commit edf3600

Please sign in to comment.