diff options
author | David Sherret <dsherret@users.noreply.github.com> | 2023-02-09 22:00:23 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-02-09 22:00:23 -0500 |
commit | b3e88e0681248631b4bf8e4d9cd2e4d2c651f333 (patch) | |
tree | cd526bb63ef712e21aef24ff77703727791f48d5 /cli/args/mod.rs | |
parent | 8da235adced567839912344ba092fb445683485a (diff) |
refactor: deno_graph 0.43 upgrade (#17692)
Diffstat (limited to 'cli/args/mod.rs')
-rw-r--r-- | cli/args/mod.rs | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/cli/args/mod.rs b/cli/args/mod.rs index d75f25d52..95dfa4535 100644 --- a/cli/args/mod.rs +++ b/cli/args/mod.rs @@ -690,16 +690,10 @@ impl CliOptions { /// Return any imports that should be brought into the scope of the module /// graph. pub fn to_maybe_imports(&self) -> MaybeImportsResult { - let mut imports = Vec::new(); if let Some(config_file) = &self.maybe_config_file { - if let Some(config_imports) = config_file.to_maybe_imports()? { - imports.extend(config_imports); - } - } - if imports.is_empty() { - Ok(None) + config_file.to_maybe_imports() } else { - Ok(Some(imports)) + Ok(Vec::new()) } } |