Revert "Merge pull request #644 from nodesagency/hotfix/beforeValidate-copy-data"

This reverts commit 0f54758e5a, reversing
changes made to b4a42e4a03.
This commit is contained in:
Jose Lorenzo Rodriguez 2012-05-09 17:58:08 -04:30
parent 2cea668755
commit e4c88d8cf9

View file

@ -2116,7 +2116,6 @@ class Model extends Object implements CakeEventListener {
} else {
$validates = $this->create($record) && $this->validates($options);
}
$data[$key] = $this->data;
if ($validates === false || (is_array($validates) && in_array(false, $validates, true))) {
$validationErrors[$key] = $this->validationErrors;
$validates = false;
@ -2125,7 +2124,6 @@ class Model extends Object implements CakeEventListener {
}
$return[$key] = $validates;
}
$this->data = $data;
$this->validationErrors = $validationErrors;
if (!$options['atomic']) {
return $return;