diff options
| author | polo <ordipolo@gmx.fr> | 2026-07-26 14:30:36 +0200 |
|---|---|---|
| committer | polo <ordipolo@gmx.fr> | 2026-07-26 14:30:36 +0200 |
| commit | 16b0a3d5fbc78837014385652a5c58b5a6c5d937 (patch) | |
| tree | b049ba5845722fc7fa3d2705ced127f10212d025 /src/controller/ContactFormController.php | |
| parent | 2c89c0ec184c0ed76562c899722bb3615cd83add (diff) | |
| download | cms-16b0a3d5fbc78837014385652a5c58b5a6c5d937.tar.gz cms-16b0a3d5fbc78837014385652a5c58b5a6c5d937.tar.bz2 cms-16b0a3d5fbc78837014385652a5c58b5a6c5d937.zip | |
Diffstat (limited to 'src/controller/ContactFormController.php')
| -rw-r--r-- | src/controller/ContactFormController.php | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/controller/ContactFormController.php b/src/controller/ContactFormController.php index e078af2..82e9b17 100644 --- a/src/controller/ContactFormController.php +++ b/src/controller/ContactFormController.php | |||
| @@ -38,7 +38,7 @@ class ContactFormController | |||
| 38 | return new JsonResponse(['success' => true]); | 38 | return new JsonResponse(['success' => true]); |
| 39 | } | 39 | } |
| 40 | else{ | 40 | else{ |
| 41 | return new JsonResponse(['success' => false, 'error' => $form->getErrors()[0]]); // la 1ère erreur sera affichée | 41 | return new JsonResponse(['success' => false, 'error' => $form->getError()]); |
| 42 | } | 42 | } |
| 43 | } | 43 | } |
| 44 | 44 | ||
| @@ -60,7 +60,7 @@ class ContactFormController | |||
| 60 | } | 60 | } |
| 61 | } | 61 | } |
| 62 | else{ | 62 | else{ |
| 63 | $error = $form->getErrors()[0]; // la 1ère erreur sera affichée | 63 | $error = $form->getError(); |
| 64 | } | 64 | } |
| 65 | 65 | ||
| 66 | if(empty($error)){ | 66 | if(empty($error)){ |
