MDL-31006 fix various notices in PHP54
PHP54 compatibility
This commit is contained in:
committed by
Eloy Lafuente (stronk7)
parent
ae924874d7
commit
b85b25ebb8
+2
-1
@@ -1318,7 +1318,7 @@ function get_config($plugin, $name = NULL) {
|
||||
if ($localcfg) {
|
||||
return (object)$localcfg;
|
||||
} else {
|
||||
return null;
|
||||
return new stdClass();
|
||||
}
|
||||
|
||||
} else {
|
||||
@@ -1869,6 +1869,7 @@ function make_timestamp($year, $month=1, $day=1, $hour=0, $minute=0, $second=0,
|
||||
$totalsecs = abs($totalsecs);
|
||||
|
||||
if (!$str) { // Create the str structure the slow way
|
||||
$str = new stdClass();
|
||||
$str->day = get_string('day');
|
||||
$str->days = get_string('days');
|
||||
$str->hour = get_string('hour');
|
||||
|
||||
Reference in New Issue
Block a user