_wp_check_for_scheduled_update_comment_type()WP 5.5.0

In order to avoid the _wp_batch_update_comment_type() job being accidentally removed, check that it's still scheduled while we haven't finished updating comment types.

Internal function — this function is designed to be used by the kernel itself. It is not recommended to use this function in your code.

No Hooks.


null. Nothing (null).




Since 5.5.0 Introduced.

_wp_check_for_scheduled_update_comment_type() code WP 6.5.2

function _wp_check_for_scheduled_update_comment_type() {
	if ( ! get_option( 'finished_updating_comment_type' ) && ! wp_next_scheduled( 'wp_update_comment_type_batch' ) ) {
		wp_schedule_single_event( time() + MINUTE_IN_SECONDS, 'wp_update_comment_type_batch' );