* @param bool $namesOnly
* Return simple list of names.
*
- * @param \Civi\ActionSchedule\Mapping|NULL $filterMapping
+ * @param \Civi\ActionSchedule\Mapping|null $filterMapping
* Filter by the schedule's mapping type.
* @param int $filterValue
* Filter by the schedule's entity_value.
*
* @return array
* (reference) reminder list
+ * @throws \CRM_Core_Exception
*/
public static function &getList($namesOnly = FALSE, $filterMapping = NULL, $filterValue = NULL) {
$query = "
CRM_Core_BAO_ActionLog::create($logParams);
}
- $dao->free();
}
}
* @param Civi\ActionSchedule\Mapping $mapping
* @param int $contactID
* @param int $entityID
- * @param int|NULL $caseID
+ * @param int|null $caseID
* @throws CRM_Core_Exception
*/
protected static function createMailingActivity($tokenRow, $mapping, $contactID, $entityID, $caseID) {
return ["sms_phone_missing" => "Couldn't find recipient's phone number."];
}
+ // dev/core#369 If an SMS provider is deleted then the relevant row in the action_schedule_table is set to NULL
+ // So we need to exclude them.
+ if (CRM_Utils_System::isNull($schedule->sms_provider_id)) {
+ return ["sms_provider_missing" => "SMS reminder cannot be sent because the SMS provider has been deleted."];
+ }
+
$messageSubject = $tokenRow->render('subject');
$sms_body_text = $tokenRow->render('sms_body_text');