MDL-45675 mod_data: initialise options as an empty array to avoid error when there are none

This commit is contained in:
Mark Nelson
2014-05-25 19:29:44 -07:00
parent 89262fa9f1
commit 33238bb24b
+1
View File
@@ -38,6 +38,7 @@ class data_field_menu extends data_field_base {
$str = '<div title="'.s($this->field->description).'">';
$options = array();
$rawoptions = explode("\n",$this->field->param1);
foreach ($rawoptions as $option) {
$option = trim($option);