Permalink
Browse files

compare search term and entry title both in lower case

  • Loading branch information...
1 parent 45190d5 commit 62cda2057874570dc22fa4501015e888a45ac66c @mustardamus mustardamus committed Jan 16, 2013
Showing with 1 addition and 2 deletions.
  1. +1 −1 app/assets/javascripts/search.js.coffee
  2. +0 −1 app/views/index.haml
@@ -64,7 +64,7 @@ class jqapi.Search
for entry in entries # go through array
titleLow = entry.title.toLowerCase() # search in lower case
- if titleLow.indexOf(term) isnt -1 # search term in title?
+ if titleLow.indexOf(term.toLowerCase()) isnt -1 # search term in title?
results.push entry # if so push entry to array
results # return result array
@@ -280,7 +280,6 @@
Released very first version.
%a#follow{:href => 'http://twitter.com/jqapi'} Follow @jqapi for updates
-
:javascript
if(window.location.hostname === 'jqapi.com') {

0 comments on commit 62cda20

Please sign in to comment.