]> scripts.mit.edu Git - autoinstalls/wordpress.git/blobdiff - wp-includes/comment.php
WordPress 4.4.1
[autoinstalls/wordpress.git] / wp-includes / comment.php
index 5de9531322a600c77fb17f5300217d79bb82c53c..9586b8b74547508f287e83b2303c9052e36054b9 100644 (file)
@@ -1805,7 +1805,7 @@ function wp_new_comment_notify_postauthor( $comment_ID ) {
        }
 
        // Only send notifications for approved comments.
-       if ( ! isset( $comment->comment_approved ) || 'spam' === $comment->comment_approved || ! $comment->comment_approved ) {
+       if ( ! isset( $comment->comment_approved ) || '1' != $comment->comment_approved ) {
                return false;
        }
 
@@ -2750,7 +2750,7 @@ function wp_handle_comment_submission( $comment_data ) {
                $comment_author       = $user->display_name;
                $comment_author_email = $user->user_email;
                $comment_author_url   = $user->user_url;
-               $user_id              = $user->ID;
+               $user_ID              = $user->ID;
                if ( current_user_can( 'unfiltered_html' ) ) {
                        if ( ! isset( $comment_data['_wp_unfiltered_html_comment'] )
                                || ! wp_verify_nonce( $comment_data['_wp_unfiltered_html_comment'], 'unfiltered-html-comment_' . $comment_post_ID )
@@ -2787,7 +2787,7 @@ function wp_handle_comment_submission( $comment_data ) {
                'comment_content',
                'comment_type',
                'comment_parent',
-               'user_id'
+               'user_ID'
        );
 
        $comment_id = wp_new_comment( wp_slash( $commentdata ) );