Adding fix for lost data in Model::afterSave();

Closes #2465, Model::save(); now returns the values of $this->data after a successful save;

git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@5894 3807eeeb-6ff5-0310-8944-8be069107fe0
This commit is contained in:
phpnut 2007-10-24 17:44:27 +00:00
parent 7b914bab9f
commit 353eab91d5

View file

@ -846,8 +846,8 @@ class Model extends Overloadable {
if ($x === $this->primaryKey) {
$this->id = $y;
}
$this->data[$n][$x] = $y;
}
$this->data[$n][$x] = $y;
}
}
}
@ -1186,6 +1186,7 @@ class Model extends Overloadable {
}
}
$this->afterSave($created);
$success = $this->data;
$this->data = false;
$this->__exists = null;
$this->_clearCache();