Changeset 39342 for trunk/src/wp-includes/rest-api/endpoints/class-wp-rest-post-statuses-controller.php
- Timestamp:
- 11/23/2016 02:42:00 AM (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/rest-api/endpoints/class-wp-rest-post-statuses-controller.php
r39313 r39342 126 126 127 127 if ( empty( $status ) ) { 128 return new WP_Error( 'rest_status_invalid', __( 'Invalid resource.' ), array( 'status' => 404 ) );128 return new WP_Error( 'rest_status_invalid', __( 'Invalid status.' ), array( 'status' => 404 ) ); 129 129 } 130 130 … … 132 132 133 133 if ( ! $check ) { 134 return new WP_Error( 'rest_cannot_read_status', __( 'Cannot view resource.' ), array( 'status' => rest_authorization_required_code() ) );134 return new WP_Error( 'rest_cannot_read_status', __( 'Cannot view status.' ), array( 'status' => rest_authorization_required_code() ) ); 135 135 } 136 136 … … 178 178 179 179 if ( empty( $obj ) ) { 180 return new WP_Error( 'rest_status_invalid', __( 'Invalid resource.' ), array( 'status' => 404 ) );180 return new WP_Error( 'rest_status_invalid', __( 'Invalid status.' ), array( 'status' => 404 ) ); 181 181 } 182 182 … … 249 249 'properties' => array( 250 250 'name' => array( 251 'description' => __( 'The title for the resource.' ),251 'description' => __( 'The title for the status.' ), 252 252 'type' => 'string', 253 253 'context' => array( 'embed', 'view', 'edit' ), … … 255 255 ), 256 256 'private' => array( 257 'description' => __( 'Whether posts with this resourceshould be private.' ),257 'description' => __( 'Whether posts with this status should be private.' ), 258 258 'type' => 'boolean', 259 259 'context' => array( 'edit' ), … … 261 261 ), 262 262 'protected' => array( 263 'description' => __( 'Whether posts with this resourceshould be protected.' ),263 'description' => __( 'Whether posts with this status should be protected.' ), 264 264 'type' => 'boolean', 265 265 'context' => array( 'edit' ), … … 267 267 ), 268 268 'public' => array( 269 'description' => __( 'Whether posts of this resourceshould be shown in the front end of the site.' ),269 'description' => __( 'Whether posts of this status should be shown in the front end of the site.' ), 270 270 'type' => 'boolean', 271 271 'context' => array( 'view', 'edit' ), … … 273 273 ), 274 274 'queryable' => array( 275 'description' => __( 'Whether posts with this resourceshould be publicly-queryable.' ),275 'description' => __( 'Whether posts with this status should be publicly-queryable.' ), 276 276 'type' => 'boolean', 277 277 'context' => array( 'view', 'edit' ), … … 285 285 ), 286 286 'slug' => array( 287 'description' => __( 'An alphanumeric identifier for the resource.' ),287 'description' => __( 'An alphanumeric identifier for the status.' ), 288 288 'type' => 'string', 289 289 'context' => array( 'embed', 'view', 'edit' ),
Note: See TracChangeset
for help on using the changeset viewer.