From f027350b3f80de7f81ad27013badb879bd515c47 Mon Sep 17 00:00:00 2001 From: Ryan Boren Date: Fri, 5 Oct 2007 16:27:48 +0000 Subject: [PATCH] Add some spacing. fixes #5137 for trunk git-svn-id: https://develop.svn.wordpress.org/trunk@6189 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-admin/includes/upload.php | 4 +++- wp-includes/query.php | 4 ++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/wp-admin/includes/upload.php b/wp-admin/includes/upload.php index b1fa9e8999..1f21426ad0 100644 --- a/wp-admin/includes/upload.php +++ b/wp-admin/includes/upload.php @@ -39,7 +39,9 @@ function wp_upload_display( $dims = false, $href = '' ) { $r .= "\t\t\t$innerHTML"; if ( $href ) $r .= "\n"; - $r .= "\t\t\t\t".size_format(filesize($filesystem_path))."\n"; + $size = @filesize($filesystem_path); + if ( !empty($size) ) + $r .= "\t\t\t\t".size_format($size)."\n"; $r .= "\n\t\t
\n\t\t\t

\n"; $r .= "\t\t\t\t\n"; $r .= "\t\t\t\t\n"; diff --git a/wp-includes/query.php b/wp-includes/query.php index 97621c6eef..8ea5bd2edf 100644 --- a/wp-includes/query.php +++ b/wp-includes/query.php @@ -1057,8 +1057,8 @@ class WP_Query { $q[$item] = array_unique($q[$item]); $tsql = "SELECT p.ID FROM $wpdb->posts p LEFT JOIN $wpdb->term_relationships tr ON (p.ID = tr.object_id) LEFT JOIN $wpdb->term_taxonomy tt ON (tr.term_taxonomy_id = tt.term_taxonomy_id) LEFT JOIN $wpdb->terms t ON (tt.term_id = t.term_id)"; - $tsql .= "WHERE tt.taxonomy = '$taxonomy' AND t.$taxonomy_field IN ('" . implode("', '", $q[$item]) . "')"; - $tsql .= "GROUP BY p.ID HAVING count(p.ID) = " . count($q[$item]); + $tsql .= " WHERE tt.taxonomy = '$taxonomy' AND t.$taxonomy_field IN ('" . implode("', '", $q[$item]) . "')"; + $tsql .= " GROUP BY p.ID HAVING count(p.ID) = " . count($q[$item]); $post_ids = $wpdb->get_col($tsql);