framework/RedKiteCms/EventSystem/Listener/PageCollection/PageRemovedListener.php
public function onPageRemoved(PageCollectionRemovedEvent $event)
    {
        $pageName = basename($event->getFilePath());
        $page = $this->pagesParser
            ->contributor($event->getUsername())
            ->parse()
            ->page($pageName);
        if (null === $page) {
            return;
        }

        foreach ($page["seo"] as $seo) {
            $permalink = $seo["permalink"];
            $this->permalinkManager->remove($permalink);
        }

        $this->permalinkManager->save();
    }
public function onPageRemoved(PageCollectionRemovedEvent $event)
    {
        $pageName = basename($event->getFilePath());
        $page = $this->pagesParser
            ->contributor($event->getUsername())
            ->parse()
            ->page($pageName);
        if (null === $page) {
            return;
        }

        foreach ($page["seo"] as $seo) {
            $permalink = $seo["permalink"];
            $this->permalinkManager->remove($permalink);
        }

        $this->permalinkManager->save();
    }
public function onPageRemoved ( PageCollectionRemovedEvent $ event ) { $ pageName = basename ( $ event -> getFilePath ( ) ) ; $ page = $ this -> pagesParser -> contributor ( $ event -> getUsername ( ) ) -> parse ( ) -> page ( $ pageName ) ; if ( null === $ page ) { return ; } foreach ( $ page [ "seo" ] as $ seo ) { $ permalink = $ seo [ "permalink" ] ; $ this -> permalinkManager -> remove ( $ permalink ) ; } $ this -> permalinkManager -> save ( ) ; }
Removes the page from PermalinkManager object

@param \RedKiteCms\EventSystem\Event\PageCollection\PageCollectionRemovedEvent $event
Removes the page from PermalinkManager object