MDL-31006 fix various notices in PHP54

PHP54 compatibility
This commit is contained in:
Petr Skoda
2012-01-18 01:03:20 +01:00
committed by Eloy Lafuente (stronk7)
parent ae924874d7
commit b85b25ebb8
34 changed files with 71 additions and 17 deletions
+3
View File
@@ -128,6 +128,9 @@ function file_prepare_standard_editor($data, $field, array $options, $context=nu
if (is_null($itemid) or is_null($context)) {
$contextid = null;
$itemid = null;
if (!isset($data)) {
$data = new stdClass();
}
if (!isset($data->{$field})) {
$data->{$field} = '';
}