We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 817bdad commit 21c18eaCopy full SHA for 21c18ea
src/Mapping/Mapper.php
@@ -36,8 +36,14 @@ public function __construct(array $mappings = null)
36
$mapping = $this->buildMapping($mappedClass);
37
38
if (false === empty($this->aliasMap[$mapping->getClassAlias()])) {
39
+
40
throw new MappingException(
- 'Class with the same name already present. Please add an alias or change an existing one.'
41
+ sprintf(
42
+ 'Class with name \'%s\' already present, used by \'%s\'. Please add an alias for \'%s\' or change an existing one.',
43
+ $mapping->getClassAlias(),
44
+ $this->aliasMap[$mapping->getClassAlias()],
45
+ $mapping->getClassName()
46
+ )
47
);
48
}
49
0 commit comments