Skip to content

Commit

Permalink
more flexible pattern for search bar
Browse files Browse the repository at this point in the history
  • Loading branch information
root committed Sep 5, 2017
1 parent e44e307 commit 6219657
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion index.html
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
function search() {
var pattern = $('#search-box').val();
var cmds = $('td').children('a');
var rg = new RegExp("^"+pattern+"$",'gi');
var rg = new RegExp(pattern,'gi');

for ( var i=0; i<cmds.length;i++ ) {
if ( (rg.exec($(cmds[i]).html())) !== null ) {
Expand Down

0 comments on commit 6219657

Please sign in to comment.