From: martin Date: Thu, 8 Aug 2002 12:41:21 +0000 (+0000) Subject: Fixed tiny buglet on insert_record which made it ignore NULL values X-Git-Url: http://git.mjollnir.org/gw?a=commitdiff_plain;h=e5a57e853ab1b04896796db8cff22cc9a7b350ab;p=moodle.git Fixed tiny buglet on insert_record which made it ignore NULL values --- diff --git a/lib/moodlelib.php b/lib/moodlelib.php index 5008942406..3000121e04 100644 --- a/lib/moodlelib.php +++ b/lib/moodlelib.php @@ -730,7 +730,7 @@ function insert_record($table, $dataobject) { // Pull out data matching these fields foreach ($columns as $column) { - if ($column->name <> "id" && $data[$column->name] ) { + if ($column->name <> "id" && isset($data[$column->name]) ) { $ddd[$column->name] = $data[$column->name]; } }