Make WordPress Core

Ticket #50805: 50805.3.patch

File 50805.3.patch, 2.3 KB (added by ramiy, 5 years ago)
  • wp-includes/rest-api/class-wp-rest-server.php

     
    959959                                if ( ! is_callable( $callback ) ) {
    960960                                        $response = new WP_Error(
    961961                                                'rest_invalid_handler',
    962                                                 __( 'The handler for the route is invalid' ),
     962                                                __( 'The handler for the route is invalid.' ),
    963963                                                array( 'status' => 500 )
    964964                                        );
    965965                                }
     
    10891089                return $this->error_to_response(
    10901090                        new WP_Error(
    10911091                                'rest_no_route',
    1092                                 __( 'No route was found matching the URL and request method' ),
     1092                                __( 'No route was found matching the URL and request method.' ),
    10931093                                array( 'status' => 404 )
    10941094                        )
    10951095                );
  • wp-includes/rest-api/endpoints/class-wp-rest-block-renderer-controller.php

     
    5151                                        'args'                => array(
    5252                                                'context'    => $this->get_context_param( array( 'default' => 'view' ) ),
    5353                                                'attributes' => array(
    54                                                         'description'       => __( 'Attributes for the block' ),
     54                                                        'description'       => __( 'Attributes for the block.' ),
    5555                                                        'type'              => 'object',
    5656                                                        'default'           => array(),
    5757                                                        'validate_callback' => static function ( $value, $request ) {
  • wp-includes/rest-api/endpoints/class-wp-rest-block-types-controller.php

     
    8787                        array(
    8888                                'args'   => array(
    8989                                        'name'      => array(
    90                                                 'description' => __( 'Block name' ),
     90                                                'description' => __( 'Block name.' ),
    9191                                                'type'        => 'string',
    9292                                        ),
    9393                                        'namespace' => array(
    94                                                 'description' => __( 'Block namespace' ),
     94                                                'description' => __( 'Block namespace.' ),
    9595                                                'type'        => 'string',
    9696                                        ),
    9797                                ),