From 3d5c0dafd062dc377de17aabcf7713f41e876cbf Mon Sep 17 00:00:00 2001 From: Michael Milette Date: Fri, 6 Sep 2024 22:45:40 -0400 Subject: [PATCH] External LTI only available in Moodle 4.3+. --- classes/text_filter.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/classes/text_filter.php b/classes/text_filter.php index 6e20c71..7db1f3f 100644 --- a/classes/text_filter.php +++ b/classes/text_filter.php @@ -942,7 +942,9 @@ private function generatortags(&$text) { $menu .= '-{getstring:filter_filtercodes}unenrolme{/getstring}|{courseunenrolurl}' . PHP_EOL; } if ($this->hasminarchetype('editingteacher')) { - $menu .= '-{getstring:mod_lti}courseexternaltools{/getstring}|/mod/lti/coursetools.php?id={courseid}' . PHP_EOL; + if ($CFG->branch >= 403) { + $menu .= '-{getstring:mod_lti}courseexternaltools{/getstring}|/mod/lti/coursetools.php?id={courseid}' . PHP_EOL; + } if ($CFG->branch >= 311) { $pluginame = '{getstring:tool_brickfield}pluginname{/getstring}'; $menu .= '-' . $pluginame . '|/admin/tool/brickfield/index.php?courseid={courseid}' . PHP_EOL;