fix: ensure valid applicant data

This commit is contained in:
Björn Fromme
2025-11-07 10:39:16 +01:00
parent 2f78ddb8ad
commit d85e81e8b9
@@ -105,6 +105,11 @@ class BookingDataProcessor
// Update applicant's data with personal data of first participant
if (false !== $firstParticipant = reset($bookingData->participants)) {
// Ensure valid nationality
if (true === empty($bookingData->applicant->nationality)) {
$bookingData->applicant->nationality = $firstParticipant->nationality;
}
$bookingData->applicant->height = $firstParticipant->height;
$bookingData->applicant->weight = $firstParticipant->weight;
$bookingData->applicant->shoeSize = $firstParticipant->shoeSize;