rustdoc: clean up redundant search hiding results code
* There's no need to call `history.replaceState` right before calling `searchState.hideResults`, which already does it. * There's no need to implement hiding search results when that is already implemented.
This commit is contained in:
parent
9d69ee0574
commit
0cd3874155
2 changed files with 1 additions and 8 deletions
|
@ -375,10 +375,7 @@ function preLoadCss(cssUrl) {
|
|||
|
||||
function handleEscape(ev) {
|
||||
searchState.clearInputTimeout();
|
||||
switchDisplayedElement(null);
|
||||
if (browserSupportsHistoryApi()) {
|
||||
history.replaceState(null, "", getNakedUrl() + window.location.hash);
|
||||
}
|
||||
searchState.hideResults();
|
||||
ev.preventDefault();
|
||||
searchState.defocus();
|
||||
window.hideAllModals(true); // true = reset focus for tooltips
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue