if ( !
empty( $body['ttl'
] ) ) { $ttl =
(int) $body['ttl'
];
if ( $ttl && ( time() +
$ttl <
wp_next_scheduled( 'wp_version_check'
) ) ) { // Queue an event to re-run the update check in $ttl seconds.
wp_schedule_single_event( time() +
$ttl, 'wp_version_check'
);
} } // Trigger background updates if running non-interactively, and we weren't called from the update handler.
if ( $doing_cron && !
doing_action( 'wp_maybe_auto_update'
) ) { /**
* Fires during wp_cron, starting the auto-update process.
*
* @since 3.9.0
*/
do_action( 'wp_maybe_auto_update'
);
}}/**
* Checks for available updates to plugins based on the latest versions hosted on WordPress.org.
*
* Despite its name this function does not actually perform any updates, it only checks for available updates.
*
* A list of all plugins installed is sent to WP, along with the site locale.
*
* Checks against the WordPress server at api.wordpress.org. Will only check
* if WordPress isn't installing.
*
* @since 2.3.0
*
* @global string $wp_version The WordPress version string.
*
* @param array $extra_stats Extra statistics to report to the WordPress.org API.
*/