Permalink
Browse files

Merge pull request #3139 branch 'hotfix/add-detail-to-exception-message'

  • Loading branch information...
2 parents b810ca1 + 0085264 commit ee42213e02034778f3bf93b1bf7e470476835f14 @Maks3w Maks3w committed Dec 3, 2012
Showing with 5 additions and 1 deletion.
  1. +5 −1 library/Zend/ServiceManager/ServiceManager.php
@@ -630,7 +630,11 @@ public function setAlias($alias, $nameOrAlias)
}
if ($this->allowOverride === false && $this->has(array($cAlias, $alias), false)) {
- throw new Exception\InvalidServiceNameException('An alias by this name already exists');
+ throw new Exception\InvalidServiceNameException(sprintf(
+ 'An alias by the name "%s" or "%s" already exists',
+ $cAlias,
+ $alias
+ ));
}
$this->aliases[$cAlias] = $nameOrAlias;

0 comments on commit ee42213

Please sign in to comment.