Changeset 31263
- Timestamp:
- 01/21/2015 11:03:48 PM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/comment.php
r31195 r31263 1926 1926 $compacted = compact( 'comment_post_ID', 'comment_author', 'comment_author_email', 'comment_author_url', 'comment_author_IP', 'comment_date', 'comment_date_gmt', 'comment_content', 'comment_karma', 'comment_approved', 'comment_agent', 'comment_type', 'comment_parent', 'user_id' ); 1927 1927 if ( ! $wpdb->insert( $wpdb->comments, $compacted ) ) { 1928 return false; 1928 $fields = array( 'comment_author', 'comment_content' ); 1929 1930 foreach( $fields as $field ) { 1931 if ( isset( $compacted[ $field ] ) ) { 1932 $post_data[ $field ] = $wpdb->strip_invalid_text_for_column( $wpdb->comments, $field, $compacted[ $field ] ); 1933 } 1934 } 1935 1936 if ( ! $wpdb->insert( $wpdb->comments, $compacted ) ) { 1937 return false; 1938 } 1929 1939 } 1930 1940
Note: See TracChangeset
for help on using the changeset viewer.