Taxonomy: Correct some strict comparisons after [45710].
See #47573. Built from https://develop.svn.wordpress.org/trunk@45711 git-svn-id: http://core.svn.wordpress.org/trunk@45522 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
3e1126d940
commit
6623a824d0
|
@ -1770,7 +1770,7 @@ function wp_delete_term( $term, $taxonomy, $args = array() ) {
|
|||
$defaults = array();
|
||||
|
||||
if ( 'category' === $taxonomy ) {
|
||||
$defaults['default'] = get_option( 'default_category' );
|
||||
$defaults['default'] = (int) get_option( 'default_category' );
|
||||
if ( $defaults['default'] === $term ) {
|
||||
return 0; // Don't delete the default category
|
||||
}
|
||||
|
@ -3541,7 +3541,7 @@ function _get_term_children( $term_id, $terms, $taxonomy, &$ancestors = array()
|
|||
continue;
|
||||
}
|
||||
|
||||
if ( $term->parent === $term_id ) {
|
||||
if ( (int) $term->parent === $term_id ) {
|
||||
if ( $use_id ) {
|
||||
$term_list[] = $term->term_id;
|
||||
} else {
|
||||
|
|
|
@ -13,7 +13,7 @@
|
|||
*
|
||||
* @global string $wp_version
|
||||
*/
|
||||
$wp_version = '5.3-alpha-45710';
|
||||
$wp_version = '5.3-alpha-45711';
|
||||
|
||||
/**
|
||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||
|
|
Loading…
Reference in New Issue