зеркало из https://github.com/mozilla/pjs.git
Fix for bug 85832 - QuickSearch should strip leading and trailing spaces.
Patch by Andreas Franke <afranke@ags.uni-sb.de>
This commit is contained in:
Родитель
0e9161edac
Коммит
46dd08d79f
|
@ -708,6 +708,9 @@ function QuickSearch ()
|
|||
{
|
||||
var input = document.f.id.value;
|
||||
|
||||
//remove leading and trailing whitespace
|
||||
input = input.replace(/^[\s]+/,"").replace(/[\s]+$/,"");
|
||||
|
||||
if (input == "")
|
||||
{
|
||||
//once this _is_ on http://bugzilla.mozilla.org, it should just return;
|
||||
|
@ -733,6 +736,10 @@ function QuickSearch ()
|
|||
|
||||
function LoadQuery() {
|
||||
var input = document.f.id.value;
|
||||
|
||||
//remove leading and trailing whitespace
|
||||
input = input.replace(/^[\s]+/,"").replace(/[\s]+$/,"");
|
||||
|
||||
Search(bugzilla+"query.cgi",input,false);
|
||||
return;
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче