Skip to content

Commit 9f12b77

Browse files
Fix saving new problems with statements
Fixes #2646. We used to persist the entity both before and after calling the lifecycle callbacks ourselves, which would introduce weird behavior where Doctrine wanted to insert some rows twice. By not persisting before calling the callbacks ourselves, this issue goes away.
1 parent 3e25ec9 commit 9f12b77

File tree

1 file changed

+0
-1
lines changed

1 file changed

+0
-1
lines changed

webapp/src/Controller/BaseController.php

-1
Original file line numberDiff line numberDiff line change
@@ -561,7 +561,6 @@ protected function processAddFormForExternalIdEntity(
561561
return $response;
562562
}
563563
} else {
564-
$this->em->persist($entity);
565564
$this->saveEntity($entity, null, true);
566565
}
567566
return $this->redirect($urlGenerator());

0 commit comments

Comments
 (0)