Reputation: 3807
I am trying to understand why CakePHP returns arrays like the following even when recursive=-1
and if there is a way to stop this from happening?
array
(
[0] => array
(
[User] => array
(
... etc...
)
)
)
Thanks,
Upvotes: 0
Views: 157
Reputation: 873
Recursive -1, reads the model without any relation.
Now brings this Array, because you do a "find (all)", you should do a "find (first)".
Upvotes: 1