DDC-2086: [GH-484] Prevented "Undefined index" notice when updating #2769

Closed
doctrinebot opened this Issue Oct 17, 2012 · 4 comments

2 participants

@doctrinebot

Jira issue originally created by user @beberlei:

This issue is created automatically through a Github pull request on behalf of jappie:

Url: #484

Message:

While executing updates on an entity scheduled for update without a change-set, an "Undefined index" notice is raised.

This issue will occur when you manually call $em()\->getUnitOfWork()\->scheduleForUpdate() on an entity that hasn't changed. The entity will be included in UnitOfWork::$entityUpdates, but because there are no changes, its oid will not be included in UnitOfWork::$entityChangeSets.

I know I'm misusing scheduleForUpdate() a bit in this case, but the notice can easily be prevented with a !empty().

@doctrinebot

Comment created by @beberlei:

A related Github Pull-Request [GH-484] was closed
#484

@doctrinebot

Comment created by @FabioBatSilva:

Merged : cd7ef6e

@doctrinebot

Issue was closed with resolution "Fixed"

@doctrinebot

Comment created by @doctrinebot:

A related Github Pull-Request [GH-484] was closed:
doctrine/dbal#484

@beberlei beberlei was assigned by doctrinebot Dec 6, 2015
@doctrinebot doctrinebot added this to the 2.3.1 milestone Dec 6, 2015
@doctrinebot doctrinebot closed this Dec 6, 2015
@doctrinebot doctrinebot added the Bug label Dec 7, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment