WordPress.org

Make WordPress Core

Ticket #16565: 16565-comment.php.patch

File 16565-comment.php.patch, 909 bytes (added by tillkruess, 4 years ago)

fixes E_NOTICE in comments.php

  • wp-includes/comment.php

     
    12651265        $commentdata['comment_content']      = apply_filters('pre_comment_content', $commentdata['comment_content']); 
    12661266        $commentdata['comment_author_IP']    = apply_filters('pre_comment_user_ip', $commentdata['comment_author_IP']); 
    12671267        $commentdata['comment_author_url']   = apply_filters('pre_comment_author_url', $commentdata['comment_author_url']); 
    1268         $commentdata['comment_author_email'] = apply_filters('pre_comment_author_email', $commentdata['comment_author_email']); 
     1268        $commentdata['comment_author_email'] = apply_filters('pre_comment_author_email', isset($commentdata['comment_author_email']) ? $commentdata['comment_author_email'] : ''); 
    12691269        $commentdata['filtered'] = true; 
    12701270        return $commentdata; 
    12711271}