Return ref. Props nbachiyski. fixes #9109

git-svn-id: https://develop.svn.wordpress.org/trunk@11216 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Ryan Boren 2009-05-06 05:03:59 +00:00
parent 9d41d07f40
commit a0f1a1c89b

View File

@ -612,8 +612,10 @@ function &get_terms($taxonomies, $args = '') {
}
foreach ( (array) $taxonomies as $taxonomy ) {
if ( ! is_taxonomy($taxonomy) )
return new WP_Error('invalid_taxonomy', __('Invalid Taxonomy'));
if ( ! is_taxonomy($taxonomy) ) {
$error = & new WP_Error('invalid_taxonomy', __('Invalid Taxonomy'));
return $error;
}
}
$in_taxonomies = "'" . implode("', '", $taxonomies) . "'";