Changeset 40514 for branches/4.7/src/wp-includes/taxonomy.php
- Timestamp:
- 04/21/2017 07:18:00 PM (9 years ago)
- Location:
- branches/4.7
- Files:
-
- 2 edited
-
. (modified) (1 prop)
-
src/wp-includes/taxonomy.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
branches/4.7
-
branches/4.7/src/wp-includes/taxonomy.php
r40354 r40514 1874 1874 $args = wp_parse_args( $args ); 1875 1875 1876 /* 1877 * When one or more queried taxonomies is registered with an 'args' array, 1878 * those params override the `$args` passed to this function. 1879 */ 1880 $terms = array(); 1881 if ( count( $taxonomies ) > 1 ) { 1882 foreach ( $taxonomies as $index => $taxonomy ) { 1883 $t = get_taxonomy( $taxonomy ); 1884 if ( isset( $t->args ) && is_array( $t->args ) && $args != array_merge( $args, $t->args ) ) { 1885 unset( $taxonomies[ $index ] ); 1886 $terms = array_merge( $terms, wp_get_object_terms( $object_ids, $taxonomy, array_merge( $args, $t->args ) ) ); 1887 } 1888 } 1889 } else { 1890 $t = get_taxonomy( $taxonomies[0] ); 1891 if ( isset( $t->args ) && is_array( $t->args ) ) { 1892 $args = array_merge( $args, $t->args ); 1893 } 1894 } 1895 1876 1896 $args['taxonomy'] = $taxonomies; 1877 1897 $args['object_ids'] = $object_ids; 1878 1898 1879 $terms = get_terms( $args);1899 $terms = array_merge( $terms, get_terms( $args ) ); 1880 1900 1881 1901 /**
Note: See TracChangeset
for help on using the changeset viewer.