Add is_wp_error check
git-svn-id: http://svn.automattic.com/wordpress/trunk@6295 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
b4cdc4435d
commit
b906aa0e86
|
@ -884,6 +884,9 @@ function wp_delete_term( $term, $taxonomy, $args = array() ) {
|
|||
|
||||
if ( ! $ids = is_term($term, $taxonomy) )
|
||||
return false;
|
||||
if ( is_wp_error( $ids ) )
|
||||
return $ids;
|
||||
|
||||
$tt_id = $ids['term_taxonomy_id'];
|
||||
|
||||
$defaults = array();
|
||||
|
|
Loading…
Reference in New Issue