From b921478cbb4df431f1bd8aee99229d9211bea1db Mon Sep 17 00:00:00 2001 From: Neil Lalonde Date: Fri, 15 Nov 2013 16:46:19 -0500 Subject: [PATCH] Use debounce to make filtering on the All Results tab faster --- .../admin/controllers/admin_site_settings_controller.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/assets/javascripts/admin/controllers/admin_site_settings_controller.js b/app/assets/javascripts/admin/controllers/admin_site_settings_controller.js index 758bddb98e5..a466dea6d86 100644 --- a/app/assets/javascripts/admin/controllers/admin_site_settings_controller.js +++ b/app/assets/javascripts/admin/controllers/admin_site_settings_controller.js @@ -16,7 +16,7 @@ Discourse.AdminSiteSettingsController = Ember.ArrayController.extend(Discourse.P @property filterContent **/ - filterContent: function() { + filterContent: Discourse.debounce(function() { // If we have no content, don't bother filtering anything if (!this.present('allSiteSettings')) return; @@ -57,6 +57,6 @@ Discourse.AdminSiteSettingsController = Ember.ArrayController.extend(Discourse.P }); this.set('model', matchesGroupedByCategory); - }.observes('filter', 'onlyOverridden') + }, 250).observes('filter', 'onlyOverridden') });