private function returnAfterRemoval(Error404 $error404)
    {
        $em = $this->getDoctrine()->getManager();

        /** @var HttpErrorRepository $errorRepository */
        $errorRepository = $em->getRepository('VictoireSeoBundle:HttpError');

        $errors = ($error404->getType() == HttpError::TYPE_ROUTE)
            ? $errorRepository->getRouteErrors()
            : $errorRepository->getFileErrors();

        if (0 == count($errors->getQuery()->getResult())) {
            return new Response($this->renderView('@VictoireSeo/Error404/_empty.html.twig'), 200, [
                'X-Inject-Alertify' => true,
            ]);
        }

        return new Response(null, 200, [
            'X-VIC-Remove'      => '100ms',
            'X-Inject-Alertify' => true,
        ]);
    }