mirror of
https://github.com/rust-lang/rust.git
synced 2025-02-05 11:33:04 +00:00
Simplify JS code a little bit
This commit is contained in:
parent
4d1bd0db7f
commit
028a3135c8
@ -328,8 +328,8 @@ pub(super) fn write_shared(
|
||||
v.push_str(
|
||||
r#"\
|
||||
]'));
|
||||
if (typeof window !== 'undefined' && window.initSearch) {window.initSearch(searchIndex)};
|
||||
if (typeof exports !== 'undefined') {exports.searchIndex = searchIndex};
|
||||
if (typeof exports !== 'undefined') exports.searchIndex = searchIndex;
|
||||
else if (window.initSearch) window.initSearch(searchIndex);
|
||||
"#,
|
||||
);
|
||||
Ok(v.into_bytes())
|
||||
|
Loading…
Reference in New Issue
Block a user