Ticket #35381: 35381.3.patch
File 35381.3.patch, 711 bytes (added by , 8 years ago) |
---|
-
src/wp-includes/class-wp-term-query.php
643 643 } 644 644 645 645 if ( empty( $terms ) ) { 646 wp_cache_add( $cache_key, array(), 'terms' , DAY_IN_SECONDS);646 wp_cache_add( $cache_key, array(), 'terms' ); 647 647 return array(); 648 648 } 649 649 … … 719 719 } 720 720 } 721 721 722 wp_cache_add( $cache_key, $terms, 'terms', DAY_IN_SECONDS ); 722 $term_ids = wp_list_pluck( $terms, 'term_id' ); 723 wp_cache_add( $cache_key, $term_ids, 'terms' ); 723 724 724 725 if ( 'all' === $_fields ) { 725 726 $terms = array_map( 'get_term', $terms );