mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2024-11-15 11:28:25 +00:00
This fixes Self Referencing Models losing data when recursive > 1 git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@3513 3807eeeb-6ff5-0310-8944-8be069107fe0
This commit is contained in:
parent
8760dce3ef
commit
fb7585e7ee
1 changed files with 3 additions and 1 deletions
|
@ -730,7 +730,9 @@ class DboSource extends DataSource {
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
if ($merge[0][$association] === false) {
|
if ($merge[0][$association] === false) {
|
||||||
$data[$association] = array();
|
if(!isset($data[$association])){
|
||||||
|
$data[$association] = array();
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
foreach($merge as $i => $row) {
|
foreach($merge as $i => $row) {
|
||||||
if (count($row) == 1) {
|
if (count($row) == 1) {
|
||||||
|
|
Loading…
Reference in a new issue