From a150c4d5496721e8b29361040512fac40ff38011 Mon Sep 17 00:00:00 2001 From: Ryan Boren Date: Mon, 19 May 2008 18:47:33 +0000 Subject: [PATCH] Make sure taxonomy args are set before using. Props Sam_a. fixes #6960 for trunk git-svn-id: https://develop.svn.wordpress.org/trunk@7952 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-includes/taxonomy.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/wp-includes/taxonomy.php b/wp-includes/taxonomy.php index 7ff488fca4..dcc0d34209 100644 --- a/wp-includes/taxonomy.php +++ b/wp-includes/taxonomy.php @@ -1057,14 +1057,14 @@ function wp_get_object_terms($object_ids, $taxonomies, $args = array()) { if ( count($taxonomies) > 1 ) { foreach ( $taxonomies as $index => $taxonomy ) { $t = get_taxonomy($taxonomy); - if ( is_array($t->args) && $args != array_merge($args, $t->args) ) { + if ( isset($t->args) && is_array($t->args) && $args != array_merge($args, $t->args) ) { unset($taxonomies[$index]); $terms = array_merge($terms, wp_get_object_terms($object_ids, $taxonomy, array_merge($args, $t->args))); } } } else { $t = get_taxonomy($taxonomies[0]); - if ( is_array($t->args) ) + if ( isset($t->args) && is_array($t->args) ) $args = array_merge($args, $t->args); }