Skip to content
Snippets Groups Projects
Commit 5b8e57a3 authored by Alessandro Elias's avatar Alessandro Elias
Browse files

Merge branch 'issue/436' into 'master'

SCRUM#436: Fix query string

See merge request !30
parents 8f73866d 7e2c1d40
Branches
Tags
1 merge request!30SCRUM#436: Fix query string
Pipeline #
le-edubar (0.1.8) testing; urgency=medium
* Fix query string
-- Andre Luis da Silva Machado <alsm14@inf.ufpr.br> Thu, 15 Mar 2018 11:18:26 -0300
le-edubar (0.1.7) testing; urgency=medium
* Update Manual Page
......
......@@ -46,9 +46,13 @@ function get_query(txt) {
/*Check if query is only blank spaces. If it is don't return
* the query*/
return query.replace(" ","","gi").length > 0 ?
"&query=" + query :
"";
var only_spaces = true;
for (var i=0; i<query.length; ++i)
if (query.charAt(i) != " ")
only_spaces = false;
return only_spaces ?
"" :
"&query=" + query;
}
/*This function clear the special chars like '&%$'
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment