Better error handling in get_meta_sql(). Props Viper007Bond. See #12891

git-svn-id: https://develop.svn.wordpress.org/trunk@16379 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
scribu 2010-11-15 10:02:39 +00:00
parent 9b80ab8ce5
commit 3d5162ecc3
1 changed files with 1 additions and 1 deletions

View File

@ -586,7 +586,7 @@ function get_tax_sql( $tax_query, $object_id_column ) {
$sql_single = get_objects_in_term( $query['terms'], $query['taxonomy'], $query ); $sql_single = get_objects_in_term( $query['terms'], $query['taxonomy'], $query );
if ( empty( $sql_single ) ) if ( empty( $sql_single ) || is_wp_error( $sql_single ) )
return ' AND 0 = 1'; return ' AND 0 = 1';
$sql[] = $sql_single; $sql[] = $sql_single;