Get correct namespace

The other one was empty, now it should be correct. Fixes #97
This commit is contained in:
Barry vd. Heuvel
2014-08-11 13:26:11 +02:00
parent 09055582af
commit 1b608fc446
+3 -1
View File
@@ -297,7 +297,9 @@ class Method
$method = $reflectionMethod->getPrototype(); $method = $reflectionMethod->getPrototype();
} }
if ($method) { if ($method) {
$phpdoc = new DocBlock($method, new Context($method->getNamespaceName())); $namespace = $method->getDeclaringClass()->getNamespaceName();
$phpdoc = new DocBlock($method, new Context($namespace));
if (strpos($phpdoc->getText(), '{@inheritdoc}') !== false) { if (strpos($phpdoc->getText(), '{@inheritdoc}') !== false) {
//Not at the end yet, try another parent/interface.. //Not at the end yet, try another parent/interface..
return $this->getInheritDoc($method); return $this->getInheritDoc($method);