From a1adf4e3497c3e74d3a15a873c6b53c3cf9af600 Mon Sep 17 00:00:00 2001 From: ryan Date: Fri, 21 Dec 2007 01:28:48 +0000 Subject: [PATCH] Better is_admin() check from filosofo and pishmishy. fixes #5487 for 2.3 git-svn-id: http://svn.automattic.com/wordpress/branches/2.3@6442 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-admin/admin.php | 2 ++ wp-includes/query.php | 6 +++--- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/wp-admin/admin.php b/wp-admin/admin.php index c0456192d6..0a6f22ae55 100644 --- a/wp-admin/admin.php +++ b/wp-admin/admin.php @@ -1,4 +1,6 @@ is_admin || (stripos($_SERVER['REQUEST_URI'], 'wp-admin/') !== false)); + if ( defined('WP_ADMIN') ) + return WP_ADMIN; + return false; } function is_archive () {