diff --git a/amd/src/util/settings.js b/amd/src/util/settings.js index b71e115..66e1416 100644 --- a/amd/src/util/settings.js +++ b/amd/src/util/settings.js @@ -5,7 +5,7 @@ import {call} from 'core/ajax'; import notification from 'core/notification'; // Prepare default value. -let settingcache = null; +let settingcache = {}; /** * Retrieve settings. diff --git a/classes/utilityservice.php b/classes/utilityservice.php index b49a3d7..4d32c60 100644 --- a/classes/utilityservice.php +++ b/classes/utilityservice.php @@ -189,6 +189,7 @@ class utilityservice extends \external_api { "enablebadges" => new \external_value(PARAM_BOOL, 'Badges are enabled in this instance'), "badges_allowcoursebadges" => new \external_value(PARAM_BOOL, 'Course badges are enabled in this instance'), "showprevnextarrows" => new \external_value(PARAM_BOOL, 'Show arrows next to the student selector'), + "enableplansharing" => new \external_value(PARAM_BOOL, 'Show arrows next to the student selector'), ]); } @@ -208,6 +209,7 @@ class utilityservice extends \external_api { "enablebadges" => !empty($CFG->enablebadges), "badges_allowcoursebadges" => !empty($CFG->badges_allowcoursebadges), "showprevnextarrows" => get_config("local_treestudyplan", "showprevnextarrows"), + "enableplansharing" => get_config("local_treestudyplan", "enableplansharing"), ]; }