From 040b8591582940de99442bb1de04afdf9d3daf59 Mon Sep 17 00:00:00 2001 From: donncha Date: Mon, 11 Dec 2006 11:45:03 +0000 Subject: WP Merge to rev 4640 git-svn-id: http://svn.automattic.com/wordpress-mu/trunk@823 7be80a69-a1ef-0310-a953-fb0f7c49ff36 --- wp-includes/query.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'wp-includes/query.php') diff --git a/wp-includes/query.php b/wp-includes/query.php index 8114bd5..05f424d 100644 --- a/wp-includes/query.php +++ b/wp-includes/query.php @@ -819,8 +819,9 @@ class WP_Query { $cat_paths = '/' . trim(urldecode($q['category_name']), '/'); $q['category_name'] = sanitize_title(basename($cat_paths)); $cat_paths = explode('/', $cat_paths); - foreach($cat_paths as $pathdir) - $cat_path .= ($pathdir!=''?'/':'') . sanitize_title($pathdir); + $cat_path = ''; + foreach ( (array) $cat_paths as $pathdir ) + $cat_path .= ( $pathdir != '' ? '/' : '' ) . sanitize_title($pathdir); //if we don't match the entire hierarchy fallback on just matching the nicename if ( empty($reqcat) ) -- cgit