mirror of
https://github.com/rust-lang/rust.git
synced 2026-05-30 21:16:27 +03:00
rustdoc: fix JS error when rendering parse error
This commit is contained in:
@@ -1724,6 +1724,10 @@ window.initSearch = rawSearchIndex => {
|
||||
`${typeFilter}</h1> in ${crates} </div>`;
|
||||
if (results.query.error !== null) {
|
||||
output += `<h3>Query parser error: "${results.query.error}".</h3>`;
|
||||
output += '<div id="titles">' +
|
||||
makeTabHeader(0, "In Names", ret_others[1]) +
|
||||
"</div>";
|
||||
currentTab = 0;
|
||||
} else if (results.query.foundElems <= 1 && results.query.returned.length === 0) {
|
||||
output += `<div id="titles">` +
|
||||
makeTabHeader(0, "In Names", ret_others[1]) +
|
||||
|
||||
Reference in New Issue
Block a user