mirror of
https://github.com/rust-lang/rust.git
synced 2026-05-22 10:05:06 +03:00
rustdoc: remove unused JS IIFE from main.js
This [IIFE] made sense when it was added in
deaf5e200e and there was a local variable
scoped to it, but now it calls a function, but declares nothing.
[IIFE]: https://developer.mozilla.org/en-US/docs/Glossary/IIFE "immediately invoked function expression"
This commit is contained in:
@@ -723,12 +723,9 @@ function loadCss(cssUrl) {
|
||||
});
|
||||
};
|
||||
|
||||
(function() {
|
||||
// To avoid checking on "rustdoc-line-numbers" value on every loop...
|
||||
if (getSettingValue("line-numbers") === "true") {
|
||||
window.rustdoc_add_line_numbers_to_examples();
|
||||
}
|
||||
}());
|
||||
if (getSettingValue("line-numbers") === "true") {
|
||||
window.rustdoc_add_line_numbers_to_examples();
|
||||
}
|
||||
|
||||
let oldSidebarScrollPosition = null;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user