X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=src%2FWallabag%2FApiBundle%2FController%2FWallabagRestController.php;h=b6b6c9bf4aee48c3496eadeb9fec631ba2173424;hb=d9b7768dca0049e76fc7b5cf6cc6cba0e2b40f3b;hp=b30ab267564740f2d6fe59cffdc27f458abb5b83;hpb=b1e92f8c14d3d506f2bfab628ba8ed95de0e8b51;p=github%2Fwallabag%2Fwallabag.git diff --git a/src/Wallabag/ApiBundle/Controller/WallabagRestController.php b/src/Wallabag/ApiBundle/Controller/WallabagRestController.php index b30ab267..b6b6c9bf 100644 --- a/src/Wallabag/ApiBundle/Controller/WallabagRestController.php +++ b/src/Wallabag/ApiBundle/Controller/WallabagRestController.php @@ -14,6 +14,7 @@ use Symfony\Component\Security\Core\Exception\AccessDeniedException; use Wallabag\CoreBundle\Entity\Entry; use Wallabag\CoreBundle\Entity\Tag; use Wallabag\AnnotationBundle\Entity\Annotation; +use Sensio\Bundle\FrameworkExtraBundle\Configuration\Route; class WallabagRestController extends FOSRestController { @@ -536,12 +537,9 @@ class WallabagRestController extends FOSRestController { $this->validateAuthentication(); - $response = $this->forward('WallabagApiBundle:WallabagRest:getAnnotations', - [ - 'entry' => $entry, - ]); - - return $response; + return $this->forward('WallabagApiBundle:WallabagRest:getAnnotations', [ + 'entry' => $entry, + ]); } /** @@ -563,13 +561,10 @@ class WallabagRestController extends FOSRestController { $this->validateAuthentication(); - $response = $this->forward('WallabagApiBundle:WallabagRest:postAnnotation', - [ + return $this->forward('WallabagApiBundle:WallabagRest:postAnnotation', [ 'request' => $request, 'entry' => $entry, ]); - - return $response; } /** @@ -592,13 +587,10 @@ class WallabagRestController extends FOSRestController { $this->validateAuthentication(); - $response = $this->forward('WallabagApiBundle:WallabagRest:putAnnotation', - [ + return $this->forward('WallabagApiBundle:WallabagRest:putAnnotation', [ 'annotation' => $annotation, 'request' => $request, ]); - - return $response; } /** @@ -620,12 +612,9 @@ class WallabagRestController extends FOSRestController { $this->validateAuthentication(); - $response = $this->forward('WallabagApiBundle:WallabagRest:deleteAnnotation', - [ + return $this->forward('WallabagApiBundle:WallabagRest:deleteAnnotation', [ 'annotation' => $annotation, ]); - - return $response; } /**