From d9b1dbbb091ef667b529af27441afba3610f8e4a Mon Sep 17 00:00:00 2001 From: Benjamin Eberlei Date: Tue, 12 Jul 2011 23:43:24 +0200 Subject: [PATCH] DDC-1244 - Fix bug with entities without namespace --- lib/Doctrine/ORM/Tools/EntityGenerator.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/Doctrine/ORM/Tools/EntityGenerator.php b/lib/Doctrine/ORM/Tools/EntityGenerator.php index 0580cb27e..f55af76b1 100644 --- a/lib/Doctrine/ORM/Tools/EntityGenerator.php +++ b/lib/Doctrine/ORM/Tools/EntityGenerator.php @@ -438,7 +438,7 @@ public function () if ($inClass) { $inClass = false; - $lastSeenClass = $lastSeenNamespace . '\\' . $token[1]; + $lastSeenClass = $lastSeenNamespace . ($lastSeenNamespace ? '\\' : '') . $token[1]; $this->_staticReflection[$lastSeenClass]['properties'] = array(); $this->_staticReflection[$lastSeenClass]['methods'] = array(); }