PluginProbe
Formidable Forms – WordPress Form Builder for Contact Forms, Calculators, Quizzes & More / 6.7
Formidable Forms – WordPress Form Builder for Contact Forms, Calculators, Quizzes & More v6.7
6.35 6.34 6.33.1 6.33 6.32.1 6.32 6.31 6.25 6.25.1 6.26 6.26.1 6.27 6.28 6.29 6.3 6.3.1 6.3.2 6.30 6.4 6.4.1 6.4.2 6.5 6.5.1 6.5.2 6.5.3 All 141 releases
← All changes | classes/controllers/FrmCronController.php +18 -0 6.5.16.7 View file →
@@ -23,10 +23,28 @@
23 23 */
24 24 private static function get_events() {
25 25 return array(
26 26 'formidable_send_usage' => 'weekly',
27 + 'frm_daily_event' => 'daily',
27 28 'frm_payment_cron' => 'daily',
28 29 );
30 + }
31 +
32 + /**
33 + * Schedules cron events.
34 + *
35 + * @since 6.7
36 + */
37 + public static function schedule_events() {
38 + $events = self::get_events();
39 + unset( $events['formidable_send_usage'] ); // This is scheduled in another place.
40 + unset( $events['frm_payment_cron'] ); // This is scheduled in another place.
41 +
42 + foreach ( $events as $event => $recurrence ) {
43 + if ( ! wp_next_scheduled( $event ) ) {
44 + wp_schedule_event( time(), $recurrence, $event );
45 + }
46 + }
29 47 }
30 48
31 49 /**
32 50 * Removes all cron events.