private function publishContentObjects(TreeObject $object)
    {
        $last = $this->objectService->createOrUpdate($object->data);

        foreach ($object->getNodes() as $subObject) {
            if ($subObject instanceof TreeObject) {
                $this->publishContentObjects($subObject);
            } else {
                /* @var ContentObject $subObject */
                $subObject->addParentLocation($last->getProperty('content_info')->mainLocationId);
                $this->objectService->createOrUpdate($subObject);
            }
        }
    }