Reverting [6224]

git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@6225 3807eeeb-6ff5-0310-8944-8be069107fe0
This commit is contained in:
phpnut 2007-12-23 11:09:45 +00:00
parent acc94e2fec
commit 22334ac248

View file

@ -1250,7 +1250,17 @@ class DboSource extends DataSource {
}
foreach ($combined as $field => $value) {
$updates[] = $this->name($field) . ' = ' . $this->value($value, $model->getColumnType($field));
if ($value === null) {
$updates[] = $this->name($field) . ' = NULL';
} else {
$update = $this->name($field) . ' = ';
if ($conditions == null) {
$update .= $this->value($value, $model->getColumnType($field));
} else {
$update .= $value;
}
$updates[] = $update;
}
}
$conditions = $this->defaultConditions($model, $conditions);