diff --git a/classes/element.php b/classes/element.php index 134414f..00331a8 100644 --- a/classes/element.php +++ b/classes/element.php @@ -358,7 +358,7 @@ abstract class element { * * @return bool returns true if the element can be added, false otherwise */ - public static function allow_add() { + public static function can_add() { return true; } diff --git a/classes/element_helper.php b/classes/element_helper.php index b9775bb..b5cb893 100644 --- a/classes/element_helper.php +++ b/classes/element_helper.php @@ -413,7 +413,7 @@ class element_helper { // Ensure the necessary class exists. if (class_exists($classname)) { // Additionally, check if the user is allowed to add the element at all. - if ($classname::allow_add()) { + if ($classname::can_add()) { $component = "customcertelement_{$foldername}"; $options[$foldername] = get_string('pluginname', $component); }