diff options
author | Gurwinder Singh <vargwin@gmail.com> | 2020-01-01 20:21:27 +0530 |
---|---|---|
committer | Ry Dahl <ry@tinyclouds.org> | 2020-01-01 09:51:27 -0500 |
commit | 55add2d366c5b3e19bd91958f3e3a36b4439839d (patch) | |
tree | 35c68bbc6140ea99c9deebe12c0fb1abc85ae2e8 /cli/lib.rs | |
parent | 4258ed262f6eed9b0ee123e1ba9c91f999f0b429 (diff) |
cleanup after tokio upgrade (#3571)
tokio_util::run and tokio::run_on_current_thread should accept Future<Output=()> instead of Future<Output=Result<(), ()>>. Currently, all the passed futures have to add Ok(()) or futures::future::ok(()) unnecessarily to call this method.
Diffstat (limited to 'cli/lib.rs')
-rw-r--r-- | cli/lib.rs | 6 |
1 files changed, 0 insertions, 6 deletions
diff --git a/cli/lib.rs b/cli/lib.rs index 096bd7abf..85133158e 100644 --- a/cli/lib.rs +++ b/cli/lib.rs @@ -269,7 +269,6 @@ fn info_command(flags: DenoFlags) { print_file_info(worker.clone(), main_module.clone()).await; let result = worker.await; js_check(result); - Ok(()) }; tokio_util::run(main_future); @@ -287,7 +286,6 @@ fn fetch_command(flags: DenoFlags) { let main_future = async move { let result = worker.execute_mod_async(&main_module, None, true).await; js_check(result); - Ok(()) }; tokio_util::run(main_future); @@ -315,7 +313,6 @@ fn eval_command(flags: DenoFlags) { let result = worker.await; js_check(result); js_check(worker_.execute("window.dispatchEvent(new Event('unload'))")); - Ok(()) }; tokio_util::run(main_future); @@ -341,7 +338,6 @@ fn bundle_command(flags: DenoFlags) { print_err_and_exit(err); } debug!(">>>>> bundle_async END"); - Ok(()) }; tokio_util::run(main_future); } @@ -358,7 +354,6 @@ fn run_repl(flags: DenoFlags) { let main_future = async move { let result = worker.await; js_check(result); - Ok(()) }; tokio_util::run(main_future); } @@ -400,7 +395,6 @@ fn run_script(flags: DenoFlags) { let result = worker.await; js_check(result); js_check(worker_.execute("window.dispatchEvent(new Event('unload'))")); - Ok(()) }; if use_current_thread { |