diff --git a/lib/Doctrine/ORM/UnitOfWork.php b/lib/Doctrine/ORM/UnitOfWork.php index 803e6683c..eb3111fb8 100644 --- a/lib/Doctrine/ORM/UnitOfWork.php +++ b/lib/Doctrine/ORM/UnitOfWork.php @@ -1735,7 +1735,7 @@ class UnitOfWork implements PropertyChangedListener $managedCol->initialize(); // clear and set dirty a managed collection if its not also the same collection to merge from. - if (!$managedCol->isEmpty() && $managedCol != $mergeCol) { + if (!$managedCol->isEmpty() && $managedCol !== $mergeCol) { $managedCol->unwrap()->clear(); $managedCol->setDirty(true);