[+BUGFIX] Extbase (Persistence): RegisterObject only is called, if there was an objec...
authorJochen Rau <j.rau@web.de>
Thu, 4 Mar 2010 06:40:59 +0000 (06:40 +0000)
committerJochen Rau <j.rau@web.de>
Thu, 4 Mar 2010 06:40:59 +0000 (06:40 +0000)
typo3/sysext/extbase/Classes/Persistence/Repository.php

index 2de04bd..7bdd61b 100644 (file)
@@ -251,8 +251,8 @@ class Tx_Extbase_Persistence_Repository implements Tx_Extbase_Persistence_Reposi
                        $object = NULL;
                        if (count($result) > 0) {
                                $object = current($result);
+                               $this->identityMap->registerObject($object, $uid);
                        }
-                       $this->identityMap->registerObject($object, $uid);
                }
                return $object;
        }