We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 1f4278d commit 5b2e477Copy full SHA for 5b2e477
src/librustdoc/html/static/main.js
@@ -605,11 +605,10 @@
605
// cleared to ensure the search is successful.
606
currentResults = null;
607
// Synchronize search bar with query string state and
608
- // perform the search, but don't empty the bar if there's
609
- // nothing there.
610
- if (params.search !== undefined) {
611
- $('.search-input').val(params.search);
612
- }
+ // perform the search. This will empty the bar if there's
+ // nothing there, which lets you really go back to a
+ // previous state with nothing in the bar.
+ $('.search-input').val(params.search);
613
// Some browsers fire 'onpopstate' for every page load
614
// (Chrome), while others fire the event only when actually
615
// popping a state (Firefox), which is why search() is
0 commit comments