From 9727ec19ee820969d1f1d6c99f369ae5ec3cae90 Mon Sep 17 00:00:00 2001 From: Jelle Besseling Date: Sun, 19 May 2024 17:26:59 +0200 Subject: [PATCH] Use getLocale method --- src/Controller/SupportMemberController.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/Controller/SupportMemberController.php b/src/Controller/SupportMemberController.php index 36d3af3..fea7bab 100644 --- a/src/Controller/SupportMemberController.php +++ b/src/Controller/SupportMemberController.php @@ -124,7 +124,7 @@ public function handleRedirect(Request $request, string $customerId): Response } $retryUrl = $this->generateUrl('support_member_retry', [ - 'customerId' => $customerId, '_locale' => $request->locale + 'customerId' => $customerId, '_locale' => $request->getLocale() ]); return $this->render('user/support_member/failed.html.twig', [ @@ -153,7 +153,7 @@ public function retryPayment(Request $request, string $customerId, TranslatorInt if ($supportMembershipApplication === null) { return $this->redirectToRoute('support_member_redirect', [ - 'customerId' => $customerId, '_locale' => $request->locale + 'customerId' => $customerId, '_locale' => $request->getLocale() ]); } else @@ -228,10 +228,10 @@ public function webhook(Request $request, MailerInterface $mailer, TranslatorInt ->to(new Address($supportMember->getEmail(), $supportMember->getFirstName() .' '. $supportMember->getLastName())) ->from(new Address($noReplyMail, 'ROOD, Socialistische Jongeren')) ->html( - $this->renderView($templatePrefix . 'email/html/welcome_support-' . $request->locale . '.html.twig', ['supportMember' => $supportMember]) + $this->renderView($templatePrefix . 'email/html/welcome_support-' . $request->getLocale() . '.html.twig', ['supportMember' => $supportMember]) ) ->text( - $this->renderView($templatePrefix . 'email/text/welcome_support-' . $request->locale . '.txt.twig', ['supportMember' => $supportMember]) + $this->renderView($templatePrefix . 'email/text/welcome_support-' . $request->getLocale() . '.txt.twig', ['supportMember' => $supportMember]) ); $mailer->send($message);