Use debounce to make filtering on the All Results tab faster

This commit is contained in:
Neil Lalonde 2013-11-15 16:46:19 -05:00
parent d3c84b60c8
commit b921478cbb
1 changed files with 2 additions and 2 deletions

View File

@ -16,7 +16,7 @@ Discourse.AdminSiteSettingsController = Ember.ArrayController.extend(Discourse.P
@property filterContent @property filterContent
**/ **/
filterContent: function() { filterContent: Discourse.debounce(function() {
// If we have no content, don't bother filtering anything // If we have no content, don't bother filtering anything
if (!this.present('allSiteSettings')) return; if (!this.present('allSiteSettings')) return;
@ -57,6 +57,6 @@ Discourse.AdminSiteSettingsController = Ember.ArrayController.extend(Discourse.P
}); });
this.set('model', matchesGroupedByCategory); this.set('model', matchesGroupedByCategory);
}.observes('filter', 'onlyOverridden') }, 250).observes('filter', 'onlyOverridden')
}); });