diff options
Diffstat (limited to 'plugins/jetpack/json-endpoints/class.wpcom-json-api-update-comment-endpoint.php')
-rw-r--r-- | plugins/jetpack/json-endpoints/class.wpcom-json-api-update-comment-endpoint.php | 10 |
1 files changed, 0 insertions, 10 deletions
diff --git a/plugins/jetpack/json-endpoints/class.wpcom-json-api-update-comment-endpoint.php b/plugins/jetpack/json-endpoints/class.wpcom-json-api-update-comment-endpoint.php index cd912132..79632dd3 100644 --- a/plugins/jetpack/json-endpoints/class.wpcom-json-api-update-comment-endpoint.php +++ b/plugins/jetpack/json-endpoints/class.wpcom-json-api-update-comment-endpoint.php @@ -173,10 +173,6 @@ class WPCOM_JSON_API_Update_Comment_Endpoint extends WPCOM_JSON_API_Comment_Endp } if ( isset( $update['comment_status'] ) ) { - if ( count( $update ) === 1 ) { - // We are only here to update the comment status so let's respond ASAP - add_action( 'wp_set_comment_status', array( $this, 'output_comment' ), 0, 1 ); - } switch ( $update['comment_status'] ) { case 'approved' : if ( 'approve' !== $comment_status ) { @@ -263,10 +259,4 @@ class WPCOM_JSON_API_Update_Comment_Endpoint extends WPCOM_JSON_API_Comment_Endp return $this->get_comment( $comment->comment_ID, $args['context'] ); } - - function output_comment( $comment_id ) { - $args = $this->query_args(); - $output = $this->get_comment( $comment_id, $args['context'] ); - $this->api->output_early( 200, $output ); - } } |