Skip to content

Commit c435ab7

Browse files
authored
Merge pull request #7 from henilp105/henilp105-search-patch#217
Resolves Issue #217
2 parents b4fbc4e + a325937 commit c435ab7

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

assets/js/package_search.js

+4-6
Original file line numberDiff line numberDiff line change
@@ -11,17 +11,15 @@ function query_params(query) {
1111
query = query.split('+').join(' ');
1212

1313
var params = {},
14-
tokens,qstring='',
14+
tokens,
1515
re = /[?&]?([^=]+)=([^&]*)/g;
1616

1717
while (tokens = re.exec(query)) {
18-
params[decodeURIComponent(tokens[1])] = decodeURIComponent(tokens[2]);
18+
params['1'] = decodeURIComponent(tokens[2]);
1919
}
20-
for( var i =0; i<query.length;i++){
21-
qstring= qstring+params[i];
22-
}
20+
2321

24-
return qstring;
22+
return params['1'];
2523
}
2624

2725
function search(data){

0 commit comments

Comments
 (0)