From 2d7fae39ce52adcf717e4bf0e6b3d32f8cc22189 Mon Sep 17 00:00:00 2001 From: Marc Koch Date: Mon, 23 Jun 2025 11:46:40 +0200 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9B=20fix=20bug:=20QueueHelper::storeE?= =?UTF-8?q?mail():=20$email=20null=20given?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Civi/Mailinglistsync/QueueHelper.php | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/Civi/Mailinglistsync/QueueHelper.php b/Civi/Mailinglistsync/QueueHelper.php index 3f250b5..036ee2a 100644 --- a/Civi/Mailinglistsync/QueueHelper.php +++ b/Civi/Mailinglistsync/QueueHelper.php @@ -106,12 +106,14 @@ class QueueHelper { * Stores an email address in the queue helper singleton. * * @param \CRM_Queue_TaskContext $context - * @param string $email + * @param string|null $email * * @return bool */ - public static function storeEmail(\CRM_Queue_TaskContext $context, string $email): bool { - self::getInstance()->addToEmails($email); + public static function storeEmail(\CRM_Queue_TaskContext $context, ?string $email): bool { + if (!empty($email)) { + self::getInstance()->addToEmails($email); + } return TRUE; }