[wp-cvs] wordpress/wp-includes functions.php,1.200,1.201
Donncha O Caoimh
donncha at users.sourceforge.net
Mon Nov 1 13:21:16 UTC 2004
Update of /cvsroot/cafelog/wordpress/wp-includes
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv19240/wp-includes
Modified Files:
functions.php
Log Message:
Make sure email and name are not blank when checking comment author in whitelist.
Index: functions.php
===================================================================
RCS file: /cvsroot/cafelog/wordpress/wp-includes/functions.php,v
retrieving revision 1.200
retrieving revision 1.201
diff -C2 -d -r1.200 -r1.201
*** functions.php 24 Oct 2004 23:48:51 -0000 1.200
--- functions.php 1 Nov 2004 13:21:14 -0000 1.201
***************
*** 1648,1655 ****
// Comment whitelisting:
if ( 1 == get_settings('comment_whitelist')) {
! $ok_to_comment = $wpdb->get_var("SELECT comment_approved FROM $wpdb->comments WHERE comment_author_email = '$email' and comment_approved = '1' ");
! if ( 1 == $ok_to_comment && false === strpos( $email, get_settings('moderation_keys')) )
return true;
! return false;
}
--- 1648,1658 ----
// Comment whitelisting:
if ( 1 == get_settings('comment_whitelist')) {
! if( $author != '' && $email != '' ) {
! $ok_to_comment = $wpdb->get_var("SELECT comment_approved FROM $wpdb->comments WHERE comment_author_email = '$email' and comment_approved = '1' ");
! if ( 1 == $ok_to_comment && false === strpos( $email, get_settings('moderation_keys')) )
return true;
! } else {
! return false;
! }
}
More information about the cvs
mailing list