mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-07-01 15:50:09 +00:00
post_exists() and comment_exists() fixes. Fixes post duplication during import. Props tott. fixes #8460
git-svn-id: https://develop.svn.wordpress.org/trunk@10722 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -19,6 +19,9 @@
|
||||
function comment_exists($comment_author, $comment_date) {
|
||||
global $wpdb;
|
||||
|
||||
$comment_author = stripslashes($comment_author);
|
||||
$comment_date = stripslashes($comment_date);
|
||||
|
||||
return $wpdb->get_var( $wpdb->prepare("SELECT comment_post_ID FROM $wpdb->comments
|
||||
WHERE comment_author = %s AND comment_date = %s", $comment_author, $comment_date) );
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user