WordPress.org

Make WordPress Core

Changeset 47625


Ignore:
Timestamp:
04/26/2020 01:12:04 PM (5 months ago)
Author:
SergeyBiryukov
Message:

Comments: Restore inclusion of an empty comment type when building the WHERE clause in WP_Comment_Query::get_comment_ids().

This ensures that get_comments( array( 'type' => 'comment' ) ) still includes comments that have not yet migrated to the comment type.

Follow-up to [47597].

Props ocean90.
See #49236.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/class-wp-comment-query.php

    r47597 r47625  
    742742                    case 'comment':
    743743                    case 'comments':
     744                        $comment_types[ $operator ][] = "''";
    744745                        $comment_types[ $operator ][] = "'comment'";
    745746                        break;
Note: See TracChangeset for help on using the changeset viewer.