Skip to content
Permalink
Browse files

clean up

  • Loading branch information...
ry committed Apr 15, 2019
1 parent edf4251 commit 872bef850e72919550f334840205681767411a32
Showing with 3 additions and 4 deletions.
  1. +3 −4 cli/ops.rs
@@ -1880,12 +1880,11 @@ fn op_create_worker(
js_check(worker.execute("denoMain()"));
js_check(worker.execute("workerMain()"));

// TODO(ry) don't use unwrap here, map into DenoError
let specifier_url = deno_dir::root_specifier_to_url(specifier).unwrap();

let result = worker.execute_mod(&specifier_url, false);
let specifier_url =
deno_dir::root_specifier_to_url(specifier).map_err(DenoError::from)?;

// TODO(ry) Use execute_mod_async here.
let result = worker.execute_mod(&specifier_url, false);
match result {
Ok(worker) => {
let mut workers_tl = parent_state.workers.lock().unwrap();

0 comments on commit 872bef8

Please sign in to comment.
You can’t perform that action at this time.