diff --git a/includes/functions.custom.php b/includes/functions.custom.php
index 45e7da1..e806a88 100644
--- a/includes/functions.custom.php
+++ b/includes/functions.custom.php
@@ -123,16 +123,16 @@ function enwiSendMailSmtp(string $html, string $subject, array $recipients, arra
if (isset($recipients[0]) && is_array($recipients[0])) {
for ($i = 0, $n = count($recipients); $i < $n; $i ++) {
if (strlen($recipients[$i]['email'])) {
- $mail->AddAddress($recipients[$i]['email'], ((strlen($recipients[$i]['name'])) ? html_entity_decode($recipients[$i]['name'], ENT_QUOTES, $encoding) : $recipients[$i]['email']));
+ $mail->AddAddress($recipients[$i]['email'], ((strlen($recipients[$i]['name']) > 0) ? html_entity_decode($recipients[$i]['name'], ENT_QUOTES, $encoding) : $recipients[$i]['email']));
}
}
} else {
- $mail->AddAddress($recipients['email'], ((strlen($recipients['name'])) ? html_entity_decode($recipients['name'], ENT_QUOTES, $encoding) : $recipients['email']));
+ $mail->AddAddress($recipients['email'], ((strlen($recipients['name']) > 0) ? html_entity_decode($recipients['name'], ENT_QUOTES, $encoding) : $recipients['email']));
}
// set replyto if needed
if(filter_var($fromEmail, FILTER_VALIDATE_EMAIL)) {
- $fromName = (strlen($fromName) > 0)?$fromName:'';
+ $fromName = (strlen($fromName) > 0)?$fromName:$fromEmail;
$mail->addReplyTo($fromEmail, $fromName);
}
diff --git a/plugin.xml b/plugin.xml
index 6cff576..f3f7507 100644
--- a/plugin.xml
+++ b/plugin.xml
@@ -9,7 +9,7 @@
PHP-Backoffice.de
info@php-backoffice.de.de
https://php-backoffice.de
- 1.0.0
+ 1.1.0