Details
-
Task
-
Status: Closed
-
Minor
-
Resolution: Fixed
-
3.4
-
MOODLE_34_STABLE
-
MOODLE_34_STABLE
-
wip-
MDL-60391-master -
Description
one single place where bennu uses function create_function that was deprecated in php 7.2
diff --git a/lib/bennu/iCalendar_properties.php b/lib/bennu/iCalendar_properties.php
|
index 260c42a..6a7a562 100644
|
--- a/lib/bennu/iCalendar_properties.php
|
+++ b/lib/bennu/iCalendar_properties.php
|
@@ -107,7 +107,10 @@ class iCalendar_property {
|
$valarray = explode('\\,', $this->value);
|
|
// Undo transparent formatting
|
- $replace_function = create_function('$a', 'return rfc2445_undo_value_formatting($a, '.$this->val_type.');');
|
+ $valtype = $this->val_type;
|
+ $replace_function = function($a) use ($valtype) {
|
+ return rfc2445_undo_value_formatting($a, $valtype);
|
+ };
|
$valarray = array_map($replace_function, $valarray);
|
|
// Now, if this property cannot have multiple values, don't return as an array
|
bennu itself seems long asleep http://bennu.sourceforge.net/