From f16aa64cf0416f6f4483e45337bea2e3fefd138a Mon Sep 17 00:00:00 2001 From: Florent DUBOST Date: Fri, 11 Oct 2013 16:40:26 +0200 Subject: [PATCH] more readable --- Extractor/ApiDocExtractor.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Extractor/ApiDocExtractor.php b/Extractor/ApiDocExtractor.php index 3535300..83bc59e 100644 --- a/Extractor/ApiDocExtractor.php +++ b/Extractor/ApiDocExtractor.php @@ -108,11 +108,11 @@ class ApiDocExtractor if ($method = $this->getReflectionMethod($route->getDefault('_controller'))) { if ($annotation = $this->reader->getMethodAnnotation($method, self::ANNOTATION_CLASS)) { if ($annotation->isResource()) { - if (!($resource = $annotation->getResource())) { + if ($resource = $annotation->getResource()) { + $resources[] = $resource; + } else { // remove format from routes used for resource grouping $resources[] = str_replace('.{_format}', '', $route->getPattern()); - } else { - $resources[] = $resource; } }