diff --git a/src/librustdoc/passes/html_tags.rs b/src/librustdoc/passes/html_tags.rs
index 1b48ce622b1f..dfc5373886a6 100644
--- a/src/librustdoc/passes/html_tags.rs
+++ b/src/librustdoc/passes/html_tags.rs
@@ -105,7 +105,7 @@ impl<'a, 'tcx> DocFolder for InvalidHtmlTagsLinter<'a, 'tcx> {
Some(hir_id) => hir_id,
None => {
// If non-local, no need to check anything.
- return None;
+ return self.fold_item_recur(item);
}
};
let dox = item.attrs.collapsed_doc_value().unwrap_or_default();
diff --git a/src/librustdoc/passes/mod.rs b/src/librustdoc/passes/mod.rs
index 3819aaee5600..a32fb10a6a78 100644
--- a/src/librustdoc/passes/mod.rs
+++ b/src/librustdoc/passes/mod.rs
@@ -104,8 +104,8 @@ pub const DEFAULT_PASSES: &[ConditionalPass] = &[
ConditionalPass::new(STRIP_PRIV_IMPORTS, WhenDocumentPrivate),
ConditionalPass::always(COLLECT_INTRA_DOC_LINKS),
ConditionalPass::always(CHECK_CODE_BLOCK_SYNTAX),
- ConditionalPass::always(PROPAGATE_DOC_CFG),
ConditionalPass::always(CHECK_INVALID_HTML_TAGS),
+ ConditionalPass::always(PROPAGATE_DOC_CFG),
];
/// The list of default passes run when `--doc-coverage` is passed to rustdoc.