Open gcskoenig opened 3 years ago
Thanks for the report and the error log,marked as a bug and will check this later.
Took a look to the file Pages/Ajax/ReservationEmailPage.php. The error seems to come from the function:
public function GetEmailAddresses() { $email = $this->GetForm('email'); return preg_split('/, ?/', $email); }
As a quick fix (I did not test it) you could try changing $email = $this->GetForm('email');
to $email = implode($this->GetForm('email'));
Hello, I have the same problem. I tested your solution and works fine with a little change: $email = implode(',',$this->GetForm('email')); Thanks a lot!
When inviting someone to an event (edit event, more, email) a menu pops up where you can enter one or multiple emails. By hitting enter they are formatted in a list. (See screenshots).
Then the email does not arrive and an error is thrown. If formatted as comma-separated list everything works. The code seems to expect a string but gets an array.
2021/11/01 22:05:12 [error] 3503#3503: *260031 FastCGI sent in stderr: "PHP message: PHP Warning: preg_split() expects parameter 2 to be string, array given in /booked/Pages/Ajax/ReservationEmailPage.php on line 53 PHP message: PHP Warning: Invalid argument supplied for foreach() in /booked/Presenters/Reservation/ReservationEmailPresenter.php on line 64" while reading response header from upstream, client: someip, server: url.de, request: "POST /booked/Web/ajax/reservation_email.php?rn=6180033972605532815057 HTTP/2.0", upstream: "fastcgi://unix:/var/run/php/php7.2-fpm.sock:", host: "url.de", referrer: "url/booked/Web/reservation.php?rn=bla"