From a0a37becbe8195cb6d33138cb22588e6d0bfd045 Mon Sep 17 00:00:00 2001 From: William Boman Date: Tue, 21 Oct 2014 01:59:35 +0200 Subject: [PATCH] Improved icon search inFilter function code. --- src/assets/js/site.js | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/src/assets/js/site.js b/src/assets/js/site.js index a84c52d8c..386aa9845 100644 --- a/src/assets/js/site.js +++ b/src/assets/js/site.js @@ -54,14 +54,10 @@ $(function() { } function inFilter(val, filter) { - var found = false; for (var i = 0; i < filter.length; i++) { - if (filter[i].match(val)) { - found = true; - break; - } + if (filter[i].match(val)) return true; } - return found; + return false; }