Make WordPress Core


Ignore:
Timestamp:
04/17/2020 07:33:52 PM (4 years ago)
Author:
SergeyBiryukov
Message:

Comments: Use comment instead of an empty string for the comment_type DB field value in comments table.

This is the first step to bring support for custom comment types into WordPress.

Add a scheduled upgrade routine to update the type value for existing comments, in batches of 100 at a time.

Props imath, aaroncampbell, jeremyfelt, dshanske.
Fixes #49236.

File:
1 edited

Legend:

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

    r47550 r47597  
    115115     *
    116116     * @since 4.4.0
    117      * @var string
    118      */
    119     public $comment_type = '';
     117     * @since 5.5.0 Default value changed to `comment`.
     118     * @var string
     119     */
     120    public $comment_type = 'comment';
    120121
    121122    /**
Note: See TracChangeset for help on using the changeset viewer.