format
This commit is contained in:
parent
e1f593fae0
commit
04d8fe5fde
@ -53,10 +53,7 @@ fn js_value_to_err(context: &str) -> impl FnOnce(JsValue) -> std::io::Error + '_
|
||||
|
||||
impl HttpWasmAssetReader {
|
||||
// Also used by HttpSourceAssetReader
|
||||
pub(crate) async fn fetch_bytes(
|
||||
&self,
|
||||
path: PathBuf,
|
||||
) -> Result<impl Reader, AssetReaderError> {
|
||||
pub(crate) async fn fetch_bytes(&self, path: PathBuf) -> Result<impl Reader, AssetReaderError> {
|
||||
// The JS global scope includes a self-reference via a specializing name, which can be used to determine the type of global context available.
|
||||
let global: Global = js_sys::global().unchecked_into();
|
||||
let promise = if !global.window().is_undefined() {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user