Ticket #22979: 22979.diff
File 22979.diff, 792 bytes (added by , 12 years ago) |
---|
-
wp-includes/comment.php
1385 1385 $commentdata['comment_parent'] = ( 'approved' == $parent_status || 'unapproved' == $parent_status ) ? $commentdata['comment_parent'] : 0; 1386 1386 1387 1387 $commentdata['comment_author_IP'] = preg_replace( '/[^0-9a-fA-F:., ]/', '',$_SERVER['REMOTE_ADDR'] ); 1388 $commentdata['comment_agent'] = substr($_SERVER['HTTP_USER_AGENT'], 0, 254);1388 $commentdata['comment_agent'] = ( isset($_SERVER['HTTP_USER_AGENT']) ? substr($_SERVER['HTTP_USER_AGENT'], 0, 254) : '' ); 1389 1389 1390 1390 $commentdata['comment_date'] = current_time('mysql'); 1391 1391 $commentdata['comment_date_gmt'] = current_time('mysql', 1);