fix grep result title

This commit is contained in:
quenousimporte 2023-11-15 22:08:52 +01:00
parent 4b4fbf4916
commit b71e5c12c4
1 changed files with 3 additions and 3 deletions

View File

@ -1656,9 +1656,9 @@ function grep(needle)
return result; return result;
} }
function showgrepresult(grepresult) function showgrepresult(needle, grepresult)
{ {
var grepcontent = ["# Search results: \"" + filter.value + "\""]; var grepcontent = ["# Search results: \"" + needle + "\""];
for (var file in grepresult) for (var file in grepresult)
{ {
grepcontent.push("[[" + file + "]]"); grepcontent.push("[[" + file + "]]");
@ -1691,7 +1691,7 @@ function showgrep()
var text = prompt("Search:"); var text = prompt("Search:");
if (text) if (text)
{ {
showgrepresult(grep(text)); showgrepresult(text, grep(text));
} }
} }