REST API: Use the integer type for page_on_front and page_for_posts options.

This adjusts the newly added options in the settings endpoint to use the `integer` type instead of `number`. Since these are page IDs and are not supposed to be floats, `integer` is the correct type.

Follow-up to [53588].

See #56058.

git-svn-id: https://develop.svn.wordpress.org/trunk@53589 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Sergey Biryukov
2022-06-29 14:15:57 +00:00
parent a0b53ac1db
commit f1b3ce0902
2 changed files with 4 additions and 4 deletions

View File

@@ -2236,7 +2236,7 @@ function register_initial_settings() {
'page_on_front',
array(
'show_in_rest' => true,
'type' => 'number',
'type' => 'integer',
'description' => __( 'The ID of the page that should be displayed on the front page' ),
)
);
@@ -2246,7 +2246,7 @@ function register_initial_settings() {
'page_for_posts',
array(
'show_in_rest' => true,
'type' => 'number',
'type' => 'integer',
'description' => __( 'The ID of the page that should display the latest posts' ),
)
);

View File

@@ -9635,12 +9635,12 @@ mockedApiResponse.Schema = {
},
"page_on_front": {
"description": "The ID of the page that should be displayed on the front page",
"type": "number",
"type": "integer",
"required": false
},
"page_for_posts": {
"description": "The ID of the page that should display the latest posts",
"type": "number",
"type": "integer",
"required": false
},
"default_ping_status": {