From b66ca19aec1a0eb6e32b25328f4ec70f78ae0e93 Mon Sep 17 00:00:00 2001 From: nacin Date: Tue, 3 Jan 2012 17:53:31 +0000 Subject: [PATCH] Fix widget count on dashboard to account for orphaned widgets. see #19553 for trunk. git-svn-id: http://svn.automattic.com/wordpress/trunk@19653 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-admin/includes/dashboard.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wp-admin/includes/dashboard.php b/wp-admin/includes/dashboard.php index 264c4f5c1a..10e29b3f2d 100644 --- a/wp-admin/includes/dashboard.php +++ b/wp-admin/includes/dashboard.php @@ -395,7 +395,7 @@ function wp_dashboard_right_now() { $sidebars_widgets = wp_get_sidebars_widgets(); $num_widgets = 0; foreach ( (array) $sidebars_widgets as $k => $v ) { - if ( 'wp_inactive_widgets' == $k ) + if ( 'wp_inactive_widgets' == $k || 'orphaned_widgets' == substr( $k, 0, 16 ) ) continue; if ( is_array($v) ) $num_widgets = $num_widgets + count($v);