Skip to content

Commit

Permalink
fix(linter): remove confusing help text for now (#7081)
Browse files Browse the repository at this point in the history
It's possible that the rule may not exist at all, or it's part of a
disabled plugin. The help text doesn't give a clue as to which is the
case currently, so it's probably less confusing to just omit it
completely.
  • Loading branch information
camchenry authored Nov 2, 2024
1 parent f543a8d commit 38d1f78
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions apps/oxlint/src/lint.rs
Original file line number Diff line number Diff line change
Expand Up @@ -126,12 +126,9 @@ impl Runner for LintRunner {
Err(err) => match err {
LinterBuilderError::UnknownRules { rules } => {
let rules = rules.iter().map(|r| r.full_name()).collect::<Vec<_>>().join("\n");
let error = Error::from(
OxcDiagnostic::warn(format!(
let error = Error::from(OxcDiagnostic::warn(format!(
"The following rules do not match the currently supported rules:\n{rules}"
))
.with_help("Check that the plugin that contains this rule is enabled."),
);
)));
return CliRunResult::LintError { error: format!("{error:?}") };
}
},
Expand Down

0 comments on commit 38d1f78

Please sign in to comment.