[DDC-1612] Cannot call entityManager->flush($entity) with new entity Created: 19/Jan/12  Updated: 22/Jan/12  Resolved: 21/Jan/12

Status: Resolved
Project: Doctrine 2 - ORM
Component/s: ORM
Affects Version/s: 2.2-BETA1, 2.2-BETA2, Git Master
Fix Version/s: 2.2.0-RC1, 2.2
Security Level: All

Type: Bug Priority: Major
Reporter: Sascha-Oliver Prolic Assignee: Benjamin Eberlei
Resolution: Fixed Votes: 0
Labels: None


 Description   

Following works:
$entity = $em->find('Entity', 1);
$entity->setName('newName');
$em->persist($entity);
$em->flush($entity);

Following does NOT work:
$entity = new Entity();
$entity->setName('newName');
$em->persist($entity);
$em->flush($entity);



 Comments   
Comment by Benjamin Eberlei [ 21/Jan/12 ]

Fixed

Generated at Sat Sep 05 01:48:24 EDT 2015 using JIRA 6.4.10#64025-sha1:5b8b74079161cd76a20ab66dda52747ee6701bd6.