Ticket #16505: check-false-get-object-terms.diff
| File check-false-get-object-terms.diff, 1.2 KB (added by wonderboymusic, 8 months ago) |
|---|
-
wp-includes/taxonomy.php
3102 3102 $t['template'] = $template; 3103 3103 3104 3104 $terms = get_object_term_cache($post->ID, $taxonomy); 3105 if ( empty($terms))3105 if ( false === $terms ) 3106 3106 $terms = wp_get_object_terms($post->ID, $taxonomy, $t['args']); 3107 3107 3108 3108 $links = array(); … … 3152 3152 return new WP_Error( 'invalid_object', __( 'Invalid object ID' ) ); 3153 3153 3154 3154 $object_terms = get_object_term_cache( $object_id, $taxonomy ); 3155 if ( empty( $object_terms ))3155 if ( false === $terms ) 3156 3156 $object_terms = wp_get_object_terms( $object_id, $taxonomy ); 3157 3157 3158 3158 if ( is_wp_error( $object_terms ) ) -
wp-admin/includes/media.php
973 973 $t['args'] = array(); 974 974 975 975 $terms = get_object_term_cache($post->ID, $taxonomy); 976 if ( empty($terms))976 if ( false === $terms ) 977 977 $terms = wp_get_object_terms($post->ID, $taxonomy, $t['args']); 978 978 979 979 $values = array();
