PluginProbe
AutomatorWP – No-Code Workflow Automation, Integration & Webhooks Plugin, now with AI / 6.0.2
AutomatorWP – No-Code Workflow Automation, Integration & Webhooks Plugin, now with AI v6.0.2
6.0.2 6.0.1 6.0.0 5.8.6 5.8.5 5.8.4 5.8.3 5.8.2 5.8.1 5.8.0 5.7.9.2 5.7.9.1 5.7.8 5.7.9 5.7.6 5.7.7 5.7.5 5.7.4 5.7.3 5.7.2 5.7.1 trunk 5.6.0 5.6.1 5.6.2 All 33 releases
automatorwp / includes / cron.php

cron.php in AutomatorWP – No-Code Workflow Automation, Integration & Webhooks Plugin, now with AI 6.0.2, at includes/cron.php

66 lines 1.3 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 * Cron
4 *
5 * @package AutomatorWP\Cron
6 * @author AutomatorWP <contact@automatorwp.com>, Ruben Garcia <rubengcdev@gmail.com>
7 * @since 1.0.0
8 */
9 // Exit if accessed directly
10 if( !defined( 'ABSPATH' ) ) exit;
11
12 require_once AUTOMATORWP_DIR . 'includes/cron/auto-logs-cleanup.php';
13 require_once AUTOMATORWP_DIR . 'includes/cron/run-scheduled-automations.php';
14
15 /**
16 * Register custom cron schedules
17 *
18 * @since 1.0.0
19 *
20 * @param array $schedules
21 *
22 * @return array
23 */
24 function automatorwp_cron_schedules( $schedules ) {
25
26 $schedules['five_minutes'] = array(
27 'interval' => 300,
28 'display' => __( 'Every five minutes', 'automatorwp' ),
29 );
30
31 return $schedules;
32
33 }
34 add_filter( 'cron_schedules', 'automatorwp_cron_schedules' );
35
36 /**
37 * Register schedule events
38 *
39 * @since 1.3.2
40 */
41 function automatorwp_schedule_events() {
42
43 /**
44 * Action triggered on activation to schedule events
45 *
46 * @since 1.3.2
47 */
48 do_action( 'automatorwp_schedule_events' );
49
50 }
51
52 /**
53 * Clear scheduled events
54 *
55 * @since 1.3.2
56 */
57 function automatorwp_clear_scheduled_events() {
58
59 /**
60 * Action triggered on deactivation to clear scheduled events
61 *
62 * @since 1.3.2
63 */
64 do_action( 'automatorwp_clear_scheduled_events' );
65
66 }