diff --git a/lib/Doctrine/ORM/UnitOfWork.php b/lib/Doctrine/ORM/UnitOfWork.php index fab0df4a1..11280b597 100644 --- a/lib/Doctrine/ORM/UnitOfWork.php +++ b/lib/Doctrine/ORM/UnitOfWork.php @@ -2195,6 +2195,11 @@ class UnitOfWork implements PropertyChangedListener } } else { $overrideLocalValues = isset($hints[Query::HINT_REFRESH]); + + // If a only a specific entity is set to refresh, check that it's the one + if(isset($hints[Query::HINT_REFRESH_ENTITY])) { + $overrideLocalValues = $hints[Query::HINT_REFRESH_ENTITY] === $entity; + } } if ($overrideLocalValues) {