1
0
mirror of synced 2025-02-20 22:23:14 +03:00

Remove some redundant clauses

This commit is contained in:
flack 2014-05-02 21:52:00 +02:00
parent 7fffba80c3
commit 5cf906d76b

View File

@ -2553,12 +2553,6 @@ class UnitOfWork implements PropertyChangedListener
if ($entity instanceof NotifyPropertyChanged) {
$entity->addPropertyChangedListener($this);
}
// inject ObjectManager into just loaded proxies.
if ($overrideLocalValues && $entity instanceof ObjectManagerAware) {
$entity->injectObjectManager($this->em, $class);
}
} else {
$overrideLocalValues = isset($hints[Query::HINT_REFRESH]);
@ -2566,14 +2560,14 @@ class UnitOfWork implements PropertyChangedListener
if (isset($hints[Query::HINT_REFRESH_ENTITY])) {
$overrideLocalValues = $hints[Query::HINT_REFRESH_ENTITY] === $entity;
}
// inject ObjectManager upon refresh.
if ($overrideLocalValues && $entity instanceof ObjectManagerAware) {
$entity->injectObjectManager($this->em, $class);
}
}
if ($overrideLocalValues) {
// inject ObjectManager upon refresh.
if ($entity instanceof ObjectManagerAware) {
$entity->injectObjectManager($this->em, $class);
}
$this->originalEntityData[$oid] = $data;
}
} else {