nextras / orm

Orm with clean object design, smart relationship loading and powerful collections.
https://nextras.org/orm
MIT License
310 stars 57 forks source link

Exception message contain name of parent Class instead of current class #274

Closed jakubboucek closed 6 years ago

jakubboucek commented 6 years ago

When I make invalid configuration of Entity, exception Nextras\Orm\InvalidStateException say:

Entity Nextras\Orm\Entity\Entity does not have defined any primary key.

instead of:

Entity App\Orm\IdentityRepository does not have defined any primary key.

Issue info

Source

https://github.com/nextras/orm/blob/28f5a41022dddadf799ad5a52222ac34e541d6d0/src/Entity/Reflection/MetadataParser.php#L450

jakubboucek commented 6 years ago

Oh no, my fault :-( Sorry.

I accidently add invalid alias at usestatement, that escaled to this weird behavior.