Document the types of two SendingQueue properties that were undocumented
It was also necessary to add an if condition to check the type of a variable before calling one of the methods of one of the documented properties. [MAILPOET-4363]
This commit is contained in:
committed by
Aschepikov
parent
f578f3f16a
commit
2c159b1694
@ -30,7 +30,10 @@ use MailPoet\WP\Functions as WPFunctions;
|
|||||||
use MailPoetVendor\Carbon\Carbon;
|
use MailPoetVendor\Carbon\Carbon;
|
||||||
|
|
||||||
class SendingQueue {
|
class SendingQueue {
|
||||||
|
/** @var MailerTask */
|
||||||
public $mailerTask;
|
public $mailerTask;
|
||||||
|
|
||||||
|
/** @var NewsletterTask */
|
||||||
public $newsletterTask;
|
public $newsletterTask;
|
||||||
|
|
||||||
const TASK_TYPE = 'sending';
|
const TASK_TYPE = 'sending';
|
||||||
@ -284,6 +287,10 @@ class SendingQueue {
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!$newsletterEntity instanceof NewsletterEntity) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
// render shortcodes and replace subscriber data in tracked links
|
// render shortcodes and replace subscriber data in tracked links
|
||||||
$preparedNewsletters[] =
|
$preparedNewsletters[] =
|
||||||
$this->newsletterTask->prepareNewsletterForSending(
|
$this->newsletterTask->prepareNewsletterForSending(
|
||||||
|
Reference in New Issue
Block a user