REST API: Move translator comments to preceding line.

Inline translator comments break POT file generation.

Props dd32.
See #38791.


git-svn-id: https://develop.svn.wordpress.org/trunk@39239 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Ryan McCue
2016-11-15 05:38:21 +00:00
parent 6fee13fda7
commit 2d0cd4493c
4 changed files with 42 additions and 21 deletions

View File

@@ -1933,7 +1933,8 @@ class WP_REST_Posts_Controller extends WP_REST_Controller {
foreach ( $taxonomies as $taxonomy ) {
$base = ! empty( $taxonomy->rest_base ) ? $taxonomy->rest_base : $taxonomy->name;
$schema['properties'][ $base ] = array(
'description' => sprintf( __( /* translators: %s: taxonomy name */ 'The terms assigned to the object in the %s taxonomy.' ), $taxonomy->name ),
/* translators: %s: taxonomy name */
'description' => sprintf( __( 'The terms assigned to the object in the %s taxonomy.' ), $taxonomy->name ),
'type' => 'array',
'items' => array(
'type' => 'integer',
@@ -2088,7 +2089,8 @@ class WP_REST_Posts_Controller extends WP_REST_Controller {
$base = ! empty( $taxonomy->rest_base ) ? $taxonomy->rest_base : $taxonomy->name;
$params[ $base ] = array(
'description' => sprintf( __( /* translators: %s: taxonomy name */ 'Limit result set to all items that have the specified term assigned in the %s taxonomy.' ), $base ),
/* translators: %s: taxonomy name */
'description' => sprintf( __( 'Limit result set to all items that have the specified term assigned in the %s taxonomy.' ), $base ),
'type' => 'array',
'items' => array(
'type' => 'integer',
@@ -2097,7 +2099,8 @@ class WP_REST_Posts_Controller extends WP_REST_Controller {
);
$params[ $base . '_exclude' ] = array(
'description' => sprintf( __( /* translators: %s: taxonomy name */ 'Limit result set to all items except those that have the specified term assigned in the %s taxonomy.' ), $base ),
/* translators: %s: taxonomy name */
'description' => sprintf( __( 'Limit result set to all items except those that have the specified term assigned in the %s taxonomy.' ), $base ),
'type' => 'array',
'items' => array(
'type' => 'integer',