REST API: After [39306], move `author_ip` argument to the correct place.

See #38822.
Built from https://develop.svn.wordpress.org/trunk@39310


git-svn-id: http://core.svn.wordpress.org/trunk@39250 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Sergey Biryukov 2016-11-19 01:51:30 +00:00
parent 5ded4db04c
commit a1f285641f
2 changed files with 2 additions and 2 deletions

View File

@ -384,7 +384,7 @@ class WP_REST_Comments_Controller extends WP_REST_Controller {
if ( empty( $_SERVER['REMOTE_ADDR'] ) || $request['author_ip'] !== $_SERVER['REMOTE_ADDR'] ) { if ( empty( $_SERVER['REMOTE_ADDR'] ) || $request['author_ip'] !== $_SERVER['REMOTE_ADDR'] ) {
return new WP_Error( 'rest_comment_invalid_author_ip', return new WP_Error( 'rest_comment_invalid_author_ip',
/* translators: %s: request parameter */ /* translators: %s: request parameter */
sprintf( __( "Sorry, you are not allowed to edit '%s' for comments.", 'author_ip' ) ), sprintf( __( "Sorry, you are not allowed to edit '%s' for comments." ), 'author_ip' ),
array( 'status' => rest_authorization_required_code() ) array( 'status' => rest_authorization_required_code() )
); );
} }

View File

@ -4,7 +4,7 @@
* *
* @global string $wp_version * @global string $wp_version
*/ */
$wp_version = '4.7-beta4-39309'; $wp_version = '4.7-beta4-39310';
/** /**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema. * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.