From 7764a278c434d66225f38ecd8c71650f669a8532 Mon Sep 17 00:00:00 2001 From: ornicar Date: Tue, 8 Jun 2010 17:35:29 +0200 Subject: [PATCH] Fix Exception message in ControllerManager --- .../Framework/WebBundle/Controller/ControllerManager.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/Symfony/Framework/WebBundle/Controller/ControllerManager.php b/src/Symfony/Framework/WebBundle/Controller/ControllerManager.php index a78615e9ce..9028daffcf 100644 --- a/src/Symfony/Framework/WebBundle/Controller/ControllerManager.php +++ b/src/Symfony/Framework/WebBundle/Controller/ControllerManager.php @@ -152,7 +152,6 @@ class ControllerManager public function getMethodArguments(array $path, $controller, $method) { $r = new \ReflectionObject($controller); - $arguments = array(); foreach ($r->getMethod($method)->getParameters() as $param) { if (array_key_exists($param->getName(), $path)) { @@ -160,7 +159,7 @@ class ControllerManager } elseif ($param->isDefaultValueAvailable()) { $arguments[] = $param->getDefaultValue(); } else { - throw new \RuntimeException(sprintf('Controller "%s::%s()" requires that you provide a value for the "$%s" argument (because there is no default value or because there is a non optional argument after this one).', $controller, $method, $param->getName())); + throw new \RuntimeException(sprintf('Controller "%s::%s()" requires that you provide a value for the "$%s" argument (because there is no default value or because there is a non optional argument after this one).', get_class($controller), $method, $param->getName())); } }