- Timestamp:
- 03/21/2019 06:58:50 PM (6 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/rest-api/endpoints/class-wp-rest-terms-controller.php
r43987 r44965 686 686 687 687 if ( isset( $request['parent'] ) && ! empty( $schema['properties']['parent'] ) ) { 688 $parent_term_id = 0; 689 $parent_term = get_term( (int) $request['parent'], $this->taxonomy ); 690 691 if ( $parent_term ) { 692 $parent_term_id = $parent_term->term_id; 688 $parent_term_id = 0; 689 $requested_parent = (int) $request['parent']; 690 691 if ( $requested_parent ) { 692 $parent_term = get_term( $requested_parent, $this->taxonomy ); 693 694 if ( $parent_term instanceof WP_Term ) { 695 $parent_term_id = $parent_term->term_id; 696 } 693 697 } 694 698
Note: See TracChangeset
for help on using the changeset viewer.