diff --git a/wp-includes/comment.php b/wp-includes/comment.php
index a8cc4dda29..21ff8c50a6 100644
a
|
b
|
function _wp_batch_update_comment_type() { |
3823 | 3823 | // Empty comment type found? We'll need to run this script again. |
3824 | 3824 | wp_schedule_single_event( time() + ( 2 * MINUTE_IN_SECONDS ), 'wp_update_comment_type_batch' ); |
3825 | 3825 | |
3826 | | // Update the `comment_type` field value to be `comment` for the next 100 rows of comments. |
| 3826 | $comment_batch_size = intval( apply_filters( 'wp_comment_batch_update_size', 100 ) ); |
| 3827 | |
| 3828 | // Update the `comment_type` field value to be `comment` for the next ($comment_batch_size) rows of comments. |
3827 | 3829 | $wpdb->query( |
3828 | 3830 | "UPDATE {$wpdb->comments} |
3829 | 3831 | SET comment_type = 'comment' |
3830 | 3832 | WHERE comment_type = '' |
3831 | 3833 | ORDER BY comment_ID DESC |
3832 | | LIMIT 100" |
| 3834 | LIMIT {$comment_batch_size}" |
3833 | 3835 | ); |
3834 | 3836 | |
3835 | 3837 | delete_option( $lock_name ); |