Skip to content

[AnnotationDriver] error in hydration classes when the property name is not equal to the attribute name #394

Closed
idetia opened this Issue Aug 17, 2012 · 3 comments

3 participants

@idetia
idetia commented Aug 17, 2012

This generate a bad hydrated class:

/**
 * @ODM\EmbedMany(
 *     targetDocument="UserBundle\Document\Message",
 *     name="incoming_messages"
 * )
 */
protected $incomingMessages = array();

And changing the attribute works fine:

/**
 * @ODM\EmbedMany(
 *     targetDocument="UserBundle\Document\Message",
 *     name="incomingMessages"
 * )
 */
protected $incomingMessages = array();
@jwage
Doctrine member
jwage commented Oct 11, 2012

What is the error you get?

@idetia
idetia commented Oct 24, 2012

The object doesn't contain any data in the bad-hydrated class property

@malarzm
Doctrine member
malarzm commented Mar 10, 2015

This is used at least few times across tests, everything seems to be fine now

@malarzm malarzm closed this Mar 10, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.