summaryrefslogtreecommitdiff
path: root/cli/main.rs
diff options
context:
space:
mode:
Diffstat (limited to 'cli/main.rs')
-rw-r--r--cli/main.rs3
1 files changed, 2 insertions, 1 deletions
diff --git a/cli/main.rs b/cli/main.rs
index 0c84e7b3e..799d47e32 100644
--- a/cli/main.rs
+++ b/cli/main.rs
@@ -532,7 +532,7 @@ async fn doc_command(
.await
};
- let doc_nodes = match parse_result {
+ let mut doc_nodes = match parse_result {
Ok(nodes) => nodes,
Err(e) => {
eprintln!("{}", e);
@@ -543,6 +543,7 @@ async fn doc_command(
if json {
write_json_to_stdout(&doc_nodes)
} else {
+ doc_nodes.retain(|doc_node| doc_node.kind != doc::DocNodeKind::Import);
let details = if let Some(filter) = maybe_filter {
let nodes =
doc::find_nodes_by_name_recursively(doc_nodes, filter.clone());