From c7dabc99eed50fa20cdcafd7c0175ab615da3d50 Mon Sep 17 00:00:00 2001 From: Ryan Dahl Date: Wed, 17 Feb 2021 13:47:18 -0500 Subject: Make ModuleSpecifier a type alias, not wrapper struct (#9531) --- runtime/ops/runtime.rs | 4 ++-- runtime/ops/worker_host.rs | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'runtime/ops') diff --git a/runtime/ops/runtime.rs b/runtime/ops/runtime.rs index 4b81c579f..77abc45b7 100644 --- a/runtime/ops/runtime.rs +++ b/runtime/ops/runtime.rs @@ -26,8 +26,8 @@ fn op_main_module( _zero_copy: &mut [ZeroCopyBuf], ) -> Result { let main = state.borrow::().to_string(); - let main_url = ModuleSpecifier::resolve_url_or_path(&main)?; - if main_url.as_url().scheme() == "file" { + let main_url = deno_core::resolve_url_or_path(&main)?; + if main_url.scheme() == "file" { let main_path = std::env::current_dir().unwrap().join(main_url.to_string()); state .borrow::() diff --git a/runtime/ops/worker_host.rs b/runtime/ops/worker_host.rs index d68fa02e8..6b375605f 100644 --- a/runtime/ops/worker_host.rs +++ b/runtime/ops/worker_host.rs @@ -482,7 +482,7 @@ fn op_create_worker( state.put::(create_module_loader.clone()); state.put::(worker_id + 1); - let module_specifier = ModuleSpecifier::resolve_url(&specifier)?; + let module_specifier = deno_core::resolve_url(&specifier)?; let worker_name = args_name.unwrap_or_else(|| "".to_string()); let (handle_sender, handle_receiver) = -- cgit v1.2.3