diff --git a/en/orm/saving-data.rst b/en/orm/saving-data.rst index 6ee1aec049..fe9ab20969 100644 --- a/en/orm/saving-data.rst +++ b/en/orm/saving-data.rst @@ -443,6 +443,8 @@ merge deeper to deeper levels, you can use the third parameter of the method:: // In a controller. $associated = ['Tags', 'Comments.Users']; + // or using nested arrays + $associated = ['Tags', 'Comments' => ['associated' => ['Users']]]; $article = $articles->get(1, ['contain' => $associated]); $articles->patchEntity($article, $this->request->getData(), [ 'associated' => $associated,