- Timestamp:
- 06/30/2021 12:33:43 PM (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/rest-api/endpoints/class-wp-rest-controller.php
r50952 r51278 505 505 * @since 4.7.0 506 506 * 507 * @global array $wp_rest_additional_fields Holds registered fields, organized by object type. 508 * 507 509 * @param string $object_type Optional. The object type. 508 * @return array Registered additional fields (if any), empty array if none or if the object type could509 * not be inferred.510 * @return array Registered additional fields (if any), empty array if none or if the object type 511 * could not be inferred. 510 512 */ 511 513 protected function get_additional_fields( $object_type = null ) { 514 global $wp_rest_additional_fields; 512 515 513 516 if ( ! $object_type ) { … … 518 521 return array(); 519 522 } 520 521 global $wp_rest_additional_fields;522 523 523 524 if ( ! $wp_rest_additional_fields || ! isset( $wp_rest_additional_fields[ $object_type ] ) ) {
Note: See TracChangeset
for help on using the changeset viewer.