Skip to content

Commit

Permalink
Merge pull request #85 from CommonGateway/fix/multipleActions
Browse files Browse the repository at this point in the history
Fix multiplying actions
  • Loading branch information
rjzondervan authored Apr 19, 2023
2 parents 8051d00 + a3b75f5 commit cff0794
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/Service/InvitePartnerService.php
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ private function createEmailAndSmsData(ObjectEntity $requester, ObjectEntity $pe
*/
private function invitePartner(array $huwelijk, string $id): ?array
{
$this->entityManager->clear();
$this->entityManager->clear('App\Entity\ObjectEntity');
$huwelijkObject = $this->entityManager->getRepository('App:ObjectEntity')->find($id);
if ($huwelijkObject instanceof ObjectEntity === false) {
$this->pluginLogger->error('Could not find huwelijk with id '.$id);
Expand Down
3 changes: 3 additions & 0 deletions src/Service/InviteWitnessService.php
Original file line number Diff line number Diff line change
Expand Up @@ -250,6 +250,9 @@ private function inviteWitness(array $huwelijk, string $id): array
$huwelijkObject = $this->updateChecklistService->checkHuwelijk($huwelijkObject);
}//end if

$this->entityManager->persist($huwelijkObject);
$this->entityManager->flush();

return $huwelijkObject->toArray();

}//end inviteWitness()
Expand Down

0 comments on commit cff0794

Please sign in to comment.