From 42fee85546de69082624ec018d891ab928c93cf2 Mon Sep 17 00:00:00 2001 From: ryan Date: Fri, 12 Oct 2007 21:47:34 +0000 Subject: [PATCH] Fix category assigment during link import. fixes #5107 for trunk git-svn-id: http://svn.automattic.com/wordpress/trunk@6233 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-includes/functions.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/wp-includes/functions.php b/wp-includes/functions.php index a575904e9f..610969689b 100644 --- a/wp-includes/functions.php +++ b/wp-includes/functions.php @@ -736,8 +736,11 @@ function wp_remote_fopen( $uri ) { function wp( $query_vars = '' ) { - global $wp; + global $wp, $wp_query, $wp_the_query; $wp->main( $query_vars ); + + if( !isset($wp_the_query) ) + $wp_the_query = $wp_query; }