Move plugin call to allow plugin authors to get in before notification is sent out.
git-svn-id: https://develop.svn.wordpress.org/trunk@1739 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
3268e7f7a2
commit
c72416ed6d
@ -77,7 +77,9 @@ VALUES
|
||||
('$comment_post_ID', '$author', '$email', '$url', '$user_ip', '$now', '$now_gmt', '$comment', '$approved', '$user_agent')
|
||||
");
|
||||
|
||||
$comment_ID = $wpdb->get_var('SELECT last_insert_id()');
|
||||
$comment_ID = $wpdb->insert_id;
|
||||
|
||||
do_action('comment_post', $comment_ID);
|
||||
|
||||
if (!$approved) {
|
||||
wp_notify_moderator($comment_ID);
|
||||
@ -87,8 +89,6 @@ if ((get_settings('comments_notify')) && ($approved)) {
|
||||
wp_notify_postauthor($comment_ID, 'comment');
|
||||
}
|
||||
|
||||
do_action('comment_post', $comment_ID);
|
||||
|
||||
setcookie('comment_author_' . $cookiehash, stripslashes($author), time() + 30000000, COOKIEPATH);
|
||||
setcookie('comment_author_email_' . $cookiehash, stripslashes($email), time() + 30000000, COOKIEPATH);
|
||||
setcookie('comment_author_url_' . $cookiehash, stripslashes($url), time() + 30000000, COOKIEPATH);
|
||||
|
Loading…
Reference in New Issue
Block a user