From c9a3cf8c5960177675a6a228b27292bf8088310e Mon Sep 17 00:00:00 2001 From: Brian Shaughnessy Date: Mon, 4 Jan 2016 06:27:52 -0500 Subject: [PATCH] CRM-17763 postMailing hook -- use mailing ID as only param --- CRM/Mailing/BAO/MailingJob.php | 3 +-- CRM/Utils/Hook.php | 9 ++++----- 2 files changed, 5 insertions(+), 7 deletions(-) diff --git a/CRM/Mailing/BAO/MailingJob.php b/CRM/Mailing/BAO/MailingJob.php index 4ec5fb4fbc..71851049de 100644 --- a/CRM/Mailing/BAO/MailingJob.php +++ b/CRM/Mailing/BAO/MailingJob.php @@ -287,8 +287,7 @@ class CRM_Mailing_BAO_MailingJob extends CRM_Mailing_DAO_MailingJob { $transaction->commit(); // CRM-17763 - $details = CRM_Mailing_BAO_Mailing::report($job->mailing_id); - CRM_Utils_Hook::postMailing($details); + CRM_Utils_Hook::postMailing($job->mailing_id); } } } diff --git a/CRM/Utils/Hook.php b/CRM/Utils/Hook.php index 8a95d958ad..ced92c3d6d 100644 --- a/CRM/Utils/Hook.php +++ b/CRM/Utils/Hook.php @@ -1571,14 +1571,13 @@ abstract class CRM_Utils_Hook { /** * This hook is called when a CiviMail mailing has completed * - * @param array $report - * Output from: CRM_Mailing_BAO_Mailing::report() - * Includes details about the mailing, including stats to date, jobs, etc. + * @param int $mailingId + * Mailing ID * * @return mixed */ - public static function postMailing($report) { - return self::singleton()->invoke(1, $report, + public static function postMailing($mailingId) { + return self::singleton()->invoke(1, $mailingId, self::$_nullObject, self::$_nullObject, self::$_nullObject, self::$_nullObject, self::$_nullObject, 'civicrm_postMailing' -- 2.25.1