public function deleteAction($id)
    {
        $manager = $this->get('opifer.redirect.redirect_manager');

        $redirect = $manager->getRepository()->find($id);

        $manager->remove($redirect);
        $this->addFlash('success', $this->get('translator')->trans('opifer_redirect.flash.deleted'));

        return $this->redirectToRoute('opifer_redirect_redirect_index');
    }
public function deleteAction($id)
    {
        $manager = $this->get('opifer.redirect.redirect_manager');

        $redirect = $manager->getRepository()->find($id);

        $manager->remove($redirect);
        $this->addFlash('success', $this->get('translator')->trans('opifer_redirect.flash.deleted'));

        return $this->redirectToRoute('opifer_redirect_redirect_index');
    }
public function deleteAction ( $ id ) { $ manager = $ this -> get ( 'opifer.redirect.redirect_manager' ) ; $ redirect = $ manager -> getRepository ( ) -> find ( $ id ) ; $ manager -> remove ( $ redirect ) ; $ this -> addFlash ( 'success' , $ this -> get ( 'translator' ) -> trans ( 'opifer_redirect.flash.deleted' ) ) ; return $ this -> redirectToRoute ( 'opifer_redirect_redirect_index' ) ; }
Delete a redirect

@param int $id

@return RedirectResponse
Delete a redirect