private function handleEntity($entity)
    {
        if (null !== $page = $this->findRelatedPage($entity)) {
            if (null === $page->getId()) {
                return;
            }
            if (!$this->pages->contains($page)) {
                $this->pages->add($page);
            }
        }
    }