Skip to content

Offline, privacy-first grammar checker. Fast, open-source, Rust-powered

fix: don't flag "need to run into" (#2437)

Andrew Dunbarfa16523207e0
diff --git a/harper-core/src/linting/need_to_noun.rs b/harper-core/src/linting/need_to_noun.rs
index 92119f3cd..ce5a8f195 100644
--- a/harper-core/src/linting/need_to_noun.rs
+++ b/harper-core/src/linting/need_to_noun.rs
@@ -24,7 +24,7 @@ impl Default for NeedToNoun {
|| tok.kind.is_unlintable()
|| tok.kind.is_pronoun()
}),
- Box::new(WordSet::new(&["about", "it"])),
+ Box::new(WordSet::new(&["about", "into", "it"])),
]);
let exceptions = SequenceExpr::anything()
@@ -449,4 +449,12 @@ mod tests {
NeedToNoun::default(),
);
}
+
+ #[test]
+ fn allows_need_to_run_into_2433() {
+ assert_no_lints(
+ "So that they don't need to run into this problem in the future.",
+ NeedToNoun::default(),
+ );
+ }
}