[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[tor-commits] [atlas/master] strip whitespaces in search



commit 5d6e5dab309472aea06d580dbc96ba50e9c2ed00
Author: Sathyanarayanan Gunasekaran <gsathya.ceg@xxxxxxxxx>
Date:   Fri Jan 4 22:05:07 2013 +0530

    strip whitespaces in search
---
 js/router.js |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/js/router.js b/js/router.js
index 3fd4a8b..543b8b4 100644
--- a/js/router.js
+++ b/js/router.js
@@ -105,6 +105,7 @@ define([
 
     $("#nav-search").submit(function(e){
         var query = _.escape($(this).children("input.search-query").val());
+        query = query.trim();
         console.log(query);
         $("#suggestion").hide();
         document.location = "#search/"+query;



_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits