From d7351f96beb6d556685955642f09c5dfa3207fe4 Mon Sep 17 00:00:00 2001 From: Ryan Boren Date: Fri, 14 Nov 2008 22:33:13 +0000 Subject: [PATCH] Use pings_open() to check ping status git-svn-id: https://develop.svn.wordpress.org/trunk@9696 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-includes/comment.php | 2 +- xmlrpc.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/wp-includes/comment.php b/wp-includes/comment.php index f2460563e0..47e51bcf88 100644 --- a/wp-includes/comment.php +++ b/wp-includes/comment.php @@ -1570,7 +1570,7 @@ function _close_comments_for_old_posts( $posts ) { } /** - * Close comments on an old post. Hooked to comments_open. + * Close comments on an old post. Hooked to comments_open and pings_open. * * @access private * @since 2.7.0 diff --git a/xmlrpc.php b/xmlrpc.php index 6a0dfcb0c9..706fd73af5 100644 --- a/xmlrpc.php +++ b/xmlrpc.php @@ -3236,7 +3236,7 @@ class wp_xmlrpc_server extends IXR_Server { return new IXR_Error(0, __('The source URL and the target URL cannot both point to the same resource.')); // Check if pings are on - if ( 'closed' == $post->ping_status ) + if ( !pings_open($post) ) return new IXR_Error(33, __('The specified target URL cannot be used as a target. It either doesn\'t exist, or it is not a pingback-enabled resource.')); // Let's check that the remote site didn't already pingback this entry