mirror of
git://develop.git.wordpress.org/
synced 2025-01-18 21:28:02 +01:00
Themes: Bail if the search term matches the currently rendered themes, Fixes the events being clobbered. Props jblz. Fixes #26347
git-svn-id: https://develop.svn.wordpress.org/trunk@26521 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
91b903fb6d
commit
63a4a1b10c
@ -97,6 +97,12 @@ themes.Collection = Backbone.Collection.extend({
|
|||||||
// and triggers an update event
|
// and triggers an update event
|
||||||
doSearch: function( value ) {
|
doSearch: function( value ) {
|
||||||
|
|
||||||
|
// Don't do anything if we've already done this search
|
||||||
|
// Useful because the Search handler fires multiple times per keystroke
|
||||||
|
if ( this.terms === value ) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
// Updates terms with the value passed
|
// Updates terms with the value passed
|
||||||
this.terms = value;
|
this.terms = value;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user