Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Copy changes made to $this->data in beforeValidate callbacks back to …

…saveAssociated data variable

This allow changes in beforeValidate to be saved
  • Loading branch information...
commit 45a86a8b20853801234f0ffb749259a24683a74c 1 parent 597913a
@jippi jippi authored
Showing with 1 addition and 0 deletions.
  1. +1 −0  lib/Cake/Model/Model.php
View
1  lib/Cake/Model/Model.php
@@ -2178,6 +2178,7 @@ public function saveAssociated($data = null, $options = array()) {
if ($options['validate'] === 'first') {
$validates = $this->validateAssociated($data, $options);
+ $data = $this->data;
if ((!$validates && $options['atomic']) || (!$options['atomic'] && in_array(false, $validates, true))) {
return $validates;
}
Please sign in to comment.
Something went wrong with that request. Please try again.