Skip to content

Commit

Permalink
Fix multiple error messages for a missing file (#2587)
Browse files Browse the repository at this point in the history
  • Loading branch information
95th authored and ry committed Jun 27, 2019
1 parent fb6d57a commit d7d3e9f
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 4 deletions.
5 changes: 1 addition & 4 deletions cli/state.rs
Expand Up @@ -181,10 +181,7 @@ impl Loader for ThreadSafeState {
self.metrics.resolve_count.fetch_add(1, Ordering::SeqCst);
Box::new(
fetch_module_meta_data_and_maybe_compile_async(self, module_specifier)
.map_err(|err| {
eprintln!("{}", err);
err
}).map(|module_meta_data| deno::SourceCodeInfo {
.map(|module_meta_data| deno::SourceCodeInfo {
// Real module name, might be different from initial URL
// due to redirections.
code: module_meta_data.js_source(),
Expand Down
1 change: 1 addition & 0 deletions tests/error_013_missing_script.out
@@ -0,0 +1 @@
Cannot resolve module "[WILDCARD]missing_file_name"
4 changes: 4 additions & 0 deletions tests/error_013_missing_script.test
@@ -0,0 +1,4 @@
args: run --reload missing_file_name
check_stderr: true
exit_code: 1
output: tests/error_013_missing_script.out

0 comments on commit d7d3e9f

Please sign in to comment.