Updating nested array of objects using $addToSet

8 posts were split to a new topic: Is it possible to set the new object data depending on the actual element in $addToSet?