public function resizeAction($imageName)
    {
        try {
            $imageOptimizer = $this->get('harentius_blog.image_optimizer');
            $imagePath = $imageOptimizer->createPreviewIfNotExists($imageName);

            return new BinaryFileResponse($imagePath);
        } catch (\Exception $e) {
            throw new NotFoundHttpException(sprintf('File %s not found', $imageName));
        }
    }