summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorandy finch <andyfinch7@gmail.com>2019-07-20 11:02:54 -0400
committerRyan Dahl <ry@tinyclouds.org>2019-07-20 11:02:54 -0400
commitc98d9bf7097575ec9832864f0e0d076a4763717c (patch)
tree65ec64885db5e4462d3412cee98c26682dfdf2d1
parent34f212f257af3ccce4a1cb8e9b75b9cb5cb1c13b (diff)
removed unnecessary implementation from SourceFileFetcher (#2670)
-rw-r--r--cli/deno_dir.rs11
1 files changed, 3 insertions, 8 deletions
diff --git a/cli/deno_dir.rs b/cli/deno_dir.rs
index 91a39543d..090f0efc9 100644
--- a/cli/deno_dir.rs
+++ b/cli/deno_dir.rs
@@ -81,7 +81,9 @@ pub trait SourceFileFetcher {
fn fetch_source_file(
self: &Self,
specifier: &ModuleSpecifier,
- ) -> Result<SourceFile, ErrBox>;
+ ) -> Result<SourceFile, ErrBox> {
+ tokio_util::block_on(self.fetch_source_file_async(specifier))
+ }
}
// TODO: this list should be implemented on SourceFileFetcher trait
@@ -235,13 +237,6 @@ impl SourceFileFetcher for DenoDir {
Box::new(fut)
}
-
- fn fetch_source_file(
- self: &Self,
- specifier: &ModuleSpecifier,
- ) -> Result<SourceFile, ErrBox> {
- tokio_util::block_on(self.fetch_source_file_async(specifier))
- }
}
// stuff related to SourceFileFetcher