Ticket #39380: 39380.1.diff
File 39380.1.diff, 1.2 KB (added by , 8 years ago) |
---|
-
src/wp-includes/comment.php
2186 2186 2187 2187 $comment_ID = $data['comment_ID']; 2188 2188 $comment_post_ID = $data['comment_post_ID']; 2189 $keys = array( 'comment_post_ID', 'comment_content', 'comment_author', 'comment_author_email', 'comment_approved', 'comment_karma', 'comment_author_url', 'comment_date', 'comment_date_gmt', 'comment_type', 'comment_parent', 'user_id', 'comment_agent', 'comment_author_IP' );2190 $data = wp_array_slice_assoc( $data, $keys );2191 2189 2192 2190 /** 2193 2191 * Filters the comment data immediately before it is updated in the database. … … 2202 2200 */ 2203 2201 $data = apply_filters( 'wp_update_comment_data', $data, $comment, $commentarr ); 2204 2202 2203 $keys = array( 'comment_post_ID', 'comment_content', 'comment_author', 'comment_author_email', 'comment_approved', 'comment_karma', 'comment_author_url', 'comment_date', 'comment_date_gmt', 'comment_type', 'comment_parent', 'user_id', 'comment_agent', 'comment_author_IP' ); 2204 $data = wp_array_slice_assoc( $data, $keys ); 2205 2205 2206 $rval = $wpdb->update( $wpdb->comments, $data, compact( 'comment_ID' ) ); 2206 2207 2207 2208 clean_comment_cache( $comment_ID );