Make WordPress Core

Ticket #38429: 38429.patch

File 38429.patch, 714 bytes (added by Soean, 9 years ago)

Adds a constructor to WP_REST_Settings_Controller.

  • src/wp-includes/rest-api/endpoints/class-wp-rest-settings-controller.php

     
    66
    77class WP_REST_Settings_Controller extends WP_REST_Controller {
    88
    9         protected $rest_base = 'settings';
    10         protected $namespace = 'wp/v2';
     9        /**
     10         * Constructor.
     11         *
     12         * @since 4.7.0
     13         */
     14        public function __construct() {
     15                $this->namespace = 'wp/v2';
     16                $this->rest_base = 'settings';
     17        }
    1118
    1219        /**
    1320         * Register the routes for the objects of the controller.