diff --git a/lib/Doctrine/ORM/Query/ResultSetMapping.php b/lib/Doctrine/ORM/Query/ResultSetMapping.php index 6e620180a..fb9215383 100644 --- a/lib/Doctrine/ORM/Query/ResultSetMapping.php +++ b/lib/Doctrine/ORM/Query/ResultSetMapping.php @@ -559,15 +559,10 @@ class ResultSetMapping $translate = function (&$alias) use ($em, $fqcn) { - if (strpos($alias, ':') !== false && !isset($fqcn[$alias])) { - if ($metadata = $em->getClassMetadata($alias)) { - $fqcn[$alias] = $metadata->name; - } - } - - if (isset($fqcn[$alias])) { - $alias = $fqcn[$alias]; + if ( ! isset($fqcn[$alias])) { + $fqcn[$alias] = $em->getClassMetadata($alias)->getName(); } + $alias = $fqcn[$alias]; }; array_walk($this->aliasMap, $translate);