This patch enables the sendmail helper sub to send emails with a non-existant
display name in the from address. This is used to replace the direct call to
the sendmail binary in pve-manager/PVE/API2/APT.pm.
Signed-off-by: Stoiko Ivanov <s.ivanov@proxmox.com>
die "illegal character in mailfrom address\n"
if $mailfrom =~ $mail_re;
- $author = $author || 'Proxmox VE';
+ $author = $author // 'Proxmox VE';
open (MAIL, "|-", "sendmail", "-B", "8BITMIME", "-f", $mailfrom, "--", @$mailto) ||
die "unable to open 'sendmail' - $!";