REST API: Use a strict `in_array()` check in `WP_REST_Meta_Fields::get_registered_fields()`.
Props dkarfa. Fixes #48839. Built from https://develop.svn.wordpress.org/trunk@46802 git-svn-id: http://core.svn.wordpress.org/trunk@46602 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
49401759f3
commit
d33571f7d5
|
@ -435,7 +435,7 @@ abstract class WP_REST_Meta_Fields {
|
||||||
|
|
||||||
$rest_args['schema'] = $this->default_additional_properties_to_false( $rest_args['schema'] );
|
$rest_args['schema'] = $this->default_additional_properties_to_false( $rest_args['schema'] );
|
||||||
|
|
||||||
if ( ! in_array( $type, array( 'string', 'boolean', 'integer', 'number', 'array', 'object' ) ) ) {
|
if ( ! in_array( $type, array( 'string', 'boolean', 'integer', 'number', 'array', 'object' ), true ) ) {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -13,7 +13,7 @@
|
||||||
*
|
*
|
||||||
* @global string $wp_version
|
* @global string $wp_version
|
||||||
*/
|
*/
|
||||||
$wp_version = '5.4-alpha-46801';
|
$wp_version = '5.4-alpha-46802';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||||
|
|
Loading…
Reference in New Issue