From 57073be14300807b79c3fd29d1baf88101fd1865 Mon Sep 17 00:00:00 2001 From: StevenDufresne Date: Mon, 11 Sep 2023 10:33:22 +0900 Subject: [PATCH] Remove the cron job after sucessfully queing everything. --- .../plugins/camptix-attendee-survey/includes/cron.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/public_html/wp-content/plugins/camptix-attendee-survey/includes/cron.php b/public_html/wp-content/plugins/camptix-attendee-survey/includes/cron.php index e666334e3..a059f3041 100644 --- a/public_html/wp-content/plugins/camptix-attendee-survey/includes/cron.php +++ b/public_html/wp-content/plugins/camptix-attendee-survey/includes/cron.php @@ -180,4 +180,7 @@ function queue_attendee_survey() { $next_time = strtotime( '+2 weeks' . wp_timezone_string() ); wp_schedule_single_event( $next_time, 'wc_attendee_disable_survey' ); } + + // Remove the cron job that queues everything. + wp_clear_scheduled_hook( 'wc_attendee_survey_email' ); }