Ticket #42343: 42343.2.diff
File 42343.2.diff, 1.3 KB (added by , 6 years ago) |
---|
-
src/wp-admin/js/customize-controls.js
1680 1680 nextTags: '', 1681 1681 filtersHeight: 0, 1682 1682 headerContainer: null, 1683 debounceUpdateCount: null, 1683 1684 1684 1685 /** 1685 1686 * Initialize. … … 1696 1697 section.$window = $( window ); 1697 1698 section.$body = $( document.body ); 1698 1699 api.Section.prototype.initialize.call( section, id, options ); 1700 section.debounceUpdateCount = _.debounce( section.updateCount, 500 ); 1699 1701 }, 1700 1702 1701 1703 /** … … 1869 1871 if ( ! section.expanded() ) { 1870 1872 section.expand(); 1871 1873 } 1872 section.checkTerm( section );1873 1874 }); 1874 1875 1875 1876 // Feature filters. … … 2240 2241 api.reflowPaneContents(); 2241 2242 2242 2243 // Update theme count. 2243 section. updateCount( count );2244 section.debounceUpdateCount( count ); 2244 2245 }, 2245 2246 2246 2247 /** … … 2255 2256 var newTerm; 2256 2257 if ( 'remote' === section.params.filter_type ) { 2257 2258 newTerm = section.contentContainer.find( '.wp-filter-search' ).val(); 2258 if ( section.term !== newTerm ) {2259 if ( section.term !== newTerm.trim() ) { 2259 2260 section.initializeNewQuery( newTerm, section.tags ); 2260 2261 } 2261 2262 }