From 380e459467846efe5c03504d5fbac6076b8fddee Mon Sep 17 00:00:00 2001 From: Mathieu Lutfy Date: Mon, 27 Mar 2023 12:08:57 -0400 Subject: [PATCH] Log sending of Scheduled Reminders They are a pain to debug when they fail because of errors with smarty or tokens --- CRM/Core/BAO/ActionSchedule.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CRM/Core/BAO/ActionSchedule.php b/CRM/Core/BAO/ActionSchedule.php index c63492d147..dbbeeac111 100644 --- a/CRM/Core/BAO/ActionSchedule.php +++ b/CRM/Core/BAO/ActionSchedule.php @@ -252,6 +252,10 @@ FROM civicrm_action_schedule cas [1 => [$actionSchedule->id, 'Integer']] ); + if ($dao->N > 0) { + Civi::log()->info("Sending Scheduled Reminder {$actionSchedule->id} to {$dao->N} recipients"); + } + $multilingual = CRM_Core_I18n::isMultilingual(); $tokenProcessor = self::createTokenProcessor($actionSchedule, $mapping); while ($dao->fetch()) { -- 2.25.1