diff --git a/lib/Doctrine/Connection/UnitOfWork.php b/lib/Doctrine/Connection/UnitOfWork.php index a4e54671c..a1542afae 100644 --- a/lib/Doctrine/Connection/UnitOfWork.php +++ b/lib/Doctrine/Connection/UnitOfWork.php @@ -265,7 +265,8 @@ class Doctrine_Connection_UnitOfWork extends Doctrine_Connection_Module $obj = $record->get($rel->getAlias()); // Protection against infinite function recursion before attempting to save - if ($obj->isModified()) { + if ($obj instanceof Doctrine_Record && + $obj->isModified()) { $obj->save($this->conn); } }