From b38b98d915a51dd7017d9b5a0baca4bad8ea6e81 Mon Sep 17 00:00:00 2001 From: Thorsten Eckel Date: Mon, 22 Jun 2015 10:49:58 +0200 Subject: [PATCH] Changed search behavior. @mrflix would be cool to combine those somehow and prioritize better matching ones? --- .../javascripts/app/lib/app_post/searchable_select.js.coffee | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/assets/javascripts/app/lib/app_post/searchable_select.js.coffee b/app/assets/javascripts/app/lib/app_post/searchable_select.js.coffee index 97731cc8a..de10d3130 100644 --- a/app/assets/javascripts/app/lib/app_post/searchable_select.js.coffee +++ b/app/assets/javascripts/app/lib/app_post/searchable_select.js.coffee @@ -103,7 +103,7 @@ class App.SearchableSelect extends Spine.Controller @filterByQuery query filterByQuery: (query) -> - regex = new RegExp(query.split('').join('.*'), 'i') + regex = new RegExp(query.split(' ').join('.*'), 'i') @values .addClass 'is-hidden'