mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2025-10-16 12:05:38 +00:00
REST API: Switch to stable version of JSON Schema.
Props danielbachhuber. Fixes #38635. git-svn-id: https://develop.svn.wordpress.org/trunk@39106 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
baf52c815a
commit
7f67e60817
@ -1088,7 +1088,7 @@ class WP_REST_Comments_Controller extends WP_REST_Controller {
|
||||
*/
|
||||
public function get_item_schema() {
|
||||
$schema = array(
|
||||
'$schema' => 'http://json-schema.org/draft-04/schema#',
|
||||
'$schema' => 'http://json-schema.org/schema#',
|
||||
'title' => 'comment',
|
||||
'type' => 'object',
|
||||
'properties' => array(
|
||||
|
||||
@ -243,7 +243,7 @@ class WP_REST_Post_Statuses_Controller extends WP_REST_Controller {
|
||||
*/
|
||||
public function get_item_schema() {
|
||||
$schema = array(
|
||||
'$schema' => 'http://json-schema.org/draft-04/schema#',
|
||||
'$schema' => 'http://json-schema.org/schema#',
|
||||
'title' => 'status',
|
||||
'type' => 'object',
|
||||
'properties' => array(
|
||||
|
||||
@ -199,7 +199,7 @@ class WP_REST_Post_Types_Controller extends WP_REST_Controller {
|
||||
*/
|
||||
public function get_item_schema() {
|
||||
$schema = array(
|
||||
'$schema' => 'http://json-schema.org/draft-04/schema#',
|
||||
'$schema' => 'http://json-schema.org/schema#',
|
||||
'title' => 'type',
|
||||
'type' => 'object',
|
||||
'properties' => array(
|
||||
|
||||
@ -1655,7 +1655,7 @@ class WP_REST_Posts_Controller extends WP_REST_Controller {
|
||||
public function get_item_schema() {
|
||||
|
||||
$schema = array(
|
||||
'$schema' => 'http://json-schema.org/draft-04/schema#',
|
||||
'$schema' => 'http://json-schema.org/schema#',
|
||||
'title' => $this->post_type,
|
||||
'type' => 'object',
|
||||
// Base properties for every Post.
|
||||
|
||||
@ -376,7 +376,7 @@ class WP_REST_Revisions_Controller extends WP_REST_Controller {
|
||||
*/
|
||||
public function get_item_schema() {
|
||||
$schema = array(
|
||||
'$schema' => 'http://json-schema.org/draft-04/schema#',
|
||||
'$schema' => 'http://json-schema.org/schema#',
|
||||
'title' => "{$this->parent_post_type}-revision",
|
||||
'type' => 'object',
|
||||
// Base properties for every Revision.
|
||||
|
||||
@ -282,7 +282,7 @@ class WP_REST_Settings_Controller extends WP_REST_Controller {
|
||||
$options = $this->get_registered_options();
|
||||
|
||||
$schema = array(
|
||||
'$schema' => 'http://json-schema.org/draft-04/schema#',
|
||||
'$schema' => 'http://json-schema.org/schema#',
|
||||
'title' => 'settings',
|
||||
'type' => 'object',
|
||||
'properties' => array(),
|
||||
|
||||
@ -230,7 +230,7 @@ class WP_REST_Taxonomies_Controller extends WP_REST_Controller {
|
||||
*/
|
||||
public function get_item_schema() {
|
||||
$schema = array(
|
||||
'$schema' => 'http://json-schema.org/draft-04/schema#',
|
||||
'$schema' => 'http://json-schema.org/schema#',
|
||||
'title' => 'taxonomy',
|
||||
'type' => 'object',
|
||||
'properties' => array(
|
||||
|
||||
@ -797,7 +797,7 @@ class WP_REST_Terms_Controller extends WP_REST_Controller {
|
||||
*/
|
||||
public function get_item_schema() {
|
||||
$schema = array(
|
||||
'$schema' => 'http://json-schema.org/draft-04/schema#',
|
||||
'$schema' => 'http://json-schema.org/schema#',
|
||||
'title' => 'post_tag' === $this->taxonomy ? 'tag' : $this->taxonomy,
|
||||
'type' => 'object',
|
||||
'properties' => array(
|
||||
|
||||
@ -995,7 +995,7 @@ class WP_REST_Users_Controller extends WP_REST_Controller {
|
||||
*/
|
||||
public function get_item_schema() {
|
||||
$schema = array(
|
||||
'$schema' => 'http://json-schema.org/draft-04/schema#',
|
||||
'$schema' => 'http://json-schema.org/schema#',
|
||||
'title' => 'user',
|
||||
'type' => 'object',
|
||||
'properties' => array(
|
||||
|
||||
Loading…
Reference in New Issue
Block a user