#225 Renamed static function
This commit is contained in:
parent
fcaf1fefd5
commit
c8939ae526
2 changed files with 2 additions and 2 deletions
|
@ -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;
|
||||
}
|
||||
|
||||
|
|
|
@ -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);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue