From 07c88e581e4c39b6df36bbd0af3b500e6f587226 Mon Sep 17 00:00:00 2001 From: westi Date: Thu, 6 Aug 2009 20:48:59 +0000 Subject: [PATCH] Ensure that XMLRPC clients can tell the difference between unapproved and spam comments. Fixes #10510 props josephscott. git-svn-id: http://svn.automattic.com/wordpress/trunk@11783 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- xmlrpc.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/xmlrpc.php b/xmlrpc.php index f7116b6d12..ac4ea4b399 100644 --- a/xmlrpc.php +++ b/xmlrpc.php @@ -1055,11 +1055,11 @@ class wp_xmlrpc_server extends IXR_Server { $comment_date = mysql2date("Ymd\TH:i:s", $comment->comment_date, false); $comment_date_gmt = mysql2date("Ymd\TH:i:s", $comment->comment_date_gmt, false); - if ( 0 == $comment->comment_approved ) + if ( '0' == $comment->comment_approved ) $comment_status = 'hold'; else if ( 'spam' == $comment->comment_approved ) $comment_status = 'spam'; - else if ( 1 == $comment->comment_approved ) + else if ( '1' == $comment->comment_approved ) $comment_status = 'approve'; else $comment_status = $comment->comment_approved;