[koji PATCH resend] Strip leading and trailing whitespace from search terms.

Chi Zhang czhang at twitter.com
Wed Feb 20 05:15:20 UTC 2013


Signed-off-by: Chi Zhang <czhang at twitter.com>
---
 www/kojiweb/index.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/www/kojiweb/index.py b/www/kojiweb/index.py
index 0505c9c..c9f8cc1 100644
--- a/www/kojiweb/index.py
+++ b/www/kojiweb/index.py
@@ -2160,7 +2160,7 @@ def search(environ, start=None, order='name'):
 
     form = environ['koji.form']
     if form.has_key('terms') and form['terms']:
-        terms = form['terms'].value
+        terms = form['terms'].value.strip()
         type = form['type'].value
         match = form['match'].value
         values['terms'] = terms
-- 
1.7.11.7



More information about the buildsys mailing list