noselusbe/noselus-frontend — pull request #65 by boisjaune (2014-10-16 02:34:14+00:00)
Title: Fixes Ember.run.debounce use in search method for politicians, questions, and questions asked by a politician

Very partly fixes #51 (the patch makes the search faster in the sense of more responsive)

The lagging problems partly come from a misuse of `Ember.run.debounce`.
The second argument to `debounce()` should be a method, like `this.execQuery`, and not the result of calling a method, like `this.execQuery(query)`. (In the latter case, `execQuery` is executed directly each time a key is pressed, and the "method" `null` is delayed to 600ms later...)
See http://emberjs.com/api/classes/Ember.run.html#method_debounce .