From: Tim Düsterhus Date: Tue, 14 Jun 2016 21:43:09 +0000 (+0200) Subject: Fix check for body in Email::getJobs() X-Git-Tag: 3.0.0_Beta_1~1442 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=997ba0afd8a4f0f3bab927713981b44a76aeb2cc;p=GitHub%2FWoltLab%2FWCF.git Fix check for body in Email::getJobs() --- diff --git a/wcfsetup/install/files/lib/system/email/Email.class.php b/wcfsetup/install/files/lib/system/email/Email.class.php index 4764f3a0cd..0dc8c46538 100644 --- a/wcfsetup/install/files/lib/system/email/Email.class.php +++ b/wcfsetup/install/files/lib/system/email/Email.class.php @@ -476,7 +476,9 @@ class Email { $this->getHeaders(); // ensure the body is filled in - $this->getBodyString(); + if ($this->body === null) { + throw new \LogicException('Cannot generate message body, you must specify a body'); + } foreach ($this->recipients as $recipient) { $mail = clone $this;