This action is performed whenever the version of Helpful does not match the stored version in the database. This action is necessary so that any newly created cron events can be scheduled correctly by WordPress.

This action does not execute itself and is only for hooking in case you also want to run something at that time. The hook is only executed during admin_init and only if the version of Helpful does not match the version in the database.

 * We will run as soon as Helpful is updated.
 * The versions you give with are optional.
 * You can control the hook without these arguments.
 * @param string $plugin_version Version
 * @param string $option_version Version in the database
 * @return void
add_action('helpful/version/refresh', function(string $plugin_version, string $option_version) {
    // your code here
}, 10, 2);

If you want to know what cron events are running on your website, you can check out the WP Crontrol plugin. The plugin is excellent for quickly and easily checking what events are actually running in the background.

Was this helpful?