From 28b7fa7d0ee1d448051155e1edae361bde521497 Mon Sep 17 00:00:00 2001 From: Benjamin Bender Date: Wed, 27 Mar 2013 22:28:26 +0100 Subject: [PATCH] Fixes typehint for Route --- Extractor/ApiDocExtractor.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Extractor/ApiDocExtractor.php b/Extractor/ApiDocExtractor.php index 142717c..7974ae6 100644 --- a/Extractor/ApiDocExtractor.php +++ b/Extractor/ApiDocExtractor.php @@ -92,7 +92,7 @@ class ApiDocExtractor * * @param \Traversable $routes \Traverseable of Route-objects for which the annotations should be extracted * - * @throws \InvalidArgumentException if one element of \Traversable does not implement RouteInterface + * @throws \InvalidArgumentException if one element of \Traversable does not implement Route * * @return array */ @@ -102,8 +102,8 @@ class ApiDocExtractor $resources = array(); foreach ($routes as $route) { - if (!($route instanceof RouterInterface)) { - throw new \InvalidArgumentException(sprintf('All elements of $routes have to implement RouteInterface. "%s" given', gettype($route))); + if (!($route instanceof Route)) { + throw new \InvalidArgumentException(sprintf('All elements of $routes must be instances of Route. "%s" given', gettype($route))); } if ($method = $this->getReflectionMethod($route->getDefault('_controller'))) {