From b71c43c51c4f8981431b6eab5da7e371dc839f8d Mon Sep 17 00:00:00 2001 From: Arne Blankerts Date: Tue, 21 Mar 2017 15:44:33 +0100 Subject: [PATCH] Tweak lookup logic --- src/generator/enricher/pmd/PHPMessDetector.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/generator/enricher/pmd/PHPMessDetector.php b/src/generator/enricher/pmd/PHPMessDetector.php index ca3a5145..3e9dcc11 100644 --- a/src/generator/enricher/pmd/PHPMessDetector.php +++ b/src/generator/enricher/pmd/PHPMessDetector.php @@ -5,6 +5,7 @@ use TheSeer\fDOM\fDOMDocument; use TheSeer\fDOM\fDOMElement; use TheSeer\fDOM\fDOMException; + use TheSeer\phpDox\FileInfo; use TheSeer\phpDox\Generator\AbstractUnitObject; use TheSeer\phpDox\Generator\ClassStartEvent; use TheSeer\phpDox\Generator\InterfaceStartEvent; @@ -58,7 +59,8 @@ private function loadViolations($xmlFile) { $dom = new fDOMDocument(); $dom->load($xmlFile); foreach($dom->query('/pmd/file') as $file) { - $this->violations[$file->getAttribute('name')] = $file->query('*'); + $fileInfo = new FileInfo($file->getAttribute('name')); + $this->violations[$fileInfo->getPathname()] = $file->query('*'); } } catch (fDOMException $e) { throw new EnricherException(