Theme Customizer: If a section has no settings, prevent it from being rendered. see #19910.

git-svn-id: https://develop.svn.wordpress.org/trunk@20251 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Daryl Koopersmith 2012-03-22 02:58:07 +00:00
parent ee5dcc012f
commit e678aca6f4

View File

@ -473,7 +473,7 @@ final class WP_Customize {
$sections = array();
foreach ( $this->sections as $section ) {
if ( ! $section->check_capabilities() )
if ( ! $section->check_capabilities() || ! $section->settings )
continue;
usort( $section->settings, array( $this, '_cmp_priority' ) );