Skip to content

Commit

Permalink
Merge pull request #97 from fluoresceco/fix-type-names
Browse files Browse the repository at this point in the history
Fix mapping of types when using a key other than the short class name
  • Loading branch information
fre5h committed Jun 6, 2017
2 parents 2008c09 + d806110 commit adf387d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion DBAL/Types/AbstractEnumType.php
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ public function requiresSQLCommentHint(AbstractPlatform $platform)
*/
public function getName()
{
return $this->name ?: (new \ReflectionClass(get_class($this)))->getShortName();
return $this->name ?: array_search(get_class($this), self::getTypesMap(), true);
}

/**
Expand Down

0 comments on commit adf387d

Please sign in to comment.