Ticket #25429: 25429.diff
| File 25429.diff, 998 bytes (added by , 13 years ago) |
|---|
-
wp-includes/category-template.php
136 136 function get_the_category_by_ID( $cat_ID ) { 137 137 $cat_ID = (int) $cat_ID; 138 138 $category = get_category( $cat_ID ); 139 if ( is_wp_error( $category ) )139 if ( null === $category || is_wp_error( $category ) ) 140 140 return $category; 141 141 return $category->name; 142 142 } -
wp-includes/category.php
80 80 */ 81 81 function get_category( $category, $output = OBJECT, $filter = 'raw' ) { 82 82 $category = get_term( $category, 'category', $output, $filter ); 83 if ( is_wp_error( $category ) )83 if ( null === $category || is_wp_error( $category ) ) 84 84 return $category; 85 85 86 86 _make_cat_compat( $category );