From 0c4613fdd217a48faebe23085839d01b8c47cd0a Mon Sep 17 00:00:00 2001 From: AD7six Date: Tue, 1 May 2012 23:39:35 +0200 Subject: [PATCH] prevent NULL in fixture files --- lib/Cake/Model/CakeSchema.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/Cake/Model/CakeSchema.php b/lib/Cake/Model/CakeSchema.php index b9ae0ad0d..74b426e40 100644 --- a/lib/Cake/Model/CakeSchema.php +++ b/lib/Cake/Model/CakeSchema.php @@ -577,6 +577,9 @@ class CakeSchema extends Object { $vals[] = "'{$key}' => array('" . implode("', '", $val) . "')"; } elseif (!is_numeric($key)) { $val = var_export($val, true); + if ($val === 'NULL') { + $val = 'null'; + } $vals[] = "'{$key}' => {$val}"; } }