Customizer: Prevent JS error during init when `nav_menus` panel is removed by plugin.
Cherry-picks [33753] onto 4.3 branch. Fixes #33411 for 4.3. Built from https://develop.svn.wordpress.org/branches/4.3@33943 git-svn-id: http://core.svn.wordpress.org/branches/4.3@33912 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
758d53b709
commit
7e56cfc30a
|
@ -119,6 +119,10 @@
|
|||
initialize: function() {
|
||||
var self = this;
|
||||
|
||||
if ( ! api.panel.has( 'nav_menus' ) ) {
|
||||
return;
|
||||
}
|
||||
|
||||
this.$search = $( '#menu-items-search' );
|
||||
this.sectionContent = this.$el.find( '.accordion-section-content' );
|
||||
|
||||
|
|
File diff suppressed because one or more lines are too long
Loading…
Reference in New Issue