From 344e15e666e10ad8c8281cc2093d2b15910ceac5 Mon Sep 17 00:00:00 2001 From: thepurpleblob Date: Tue, 24 Mar 2009 11:12:33 +0000 Subject: [PATCH] MDL-18542: Just noticed a couple of oddnesses in the diff..... --- mod/data/edit.php | 4 ---- mod/data/lib.php | 5 +++++ 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/mod/data/edit.php b/mod/data/edit.php index 84609ff288..eb8262ec8f 100755 --- a/mod/data/edit.php +++ b/mod/data/edit.php @@ -145,10 +145,6 @@ $ignorenames = array('MAX_FILE_SIZE','sesskey','d','rid','saveandview','cancel'); // strings to be ignored in input data - $ignorenames = array('MAX_FILE_SIZE','sesskey','d','rid','saveandview','cancel'); // strings to be ignored in input data - - $ignorenames = array('MAX_FILE_SIZE','sesskey','d','rid','saveandview','cancel'); // strings to be ignored in input data - if ($rid) { /// Update some records /// All student edits are marked unapproved by default diff --git a/mod/data/lib.php b/mod/data/lib.php index eb7835e789..a36e251bcc 100755 --- a/mod/data/lib.php +++ b/mod/data/lib.php @@ -193,6 +193,11 @@ class data_field_base { // Base class for Database Field Types (see field/*/ $content = ''; } + // beware get_field returns false for new, empty records MDL-18567 + if ($content===false) { + $content=''; + } + $str = '
'; $str .= ''; $str .= '
'; -- 2.39.5