Auto merge of #18197 - alibektas:buggy_flycheck_message, r=Veykril

minor: Stricter requirements for package wide flycheck

Require the existence of a target and `check_workspace` to be false to restart package-wide flycheck. Fixes #18194 , #18104
This commit is contained in:
bors 2024-09-27 05:14:35 +00:00
commit c482421316

View file

@ -380,7 +380,7 @@ fn run_flycheck(state: &mut GlobalState, vfs_path: VfsPath) -> bool {
if id == flycheck.id() {
updated = true;
match package.filter(|_| {
!world.config.flycheck_workspace(source_root_id) || target.is_some()
!world.config.flycheck_workspace(source_root_id) && target.is_some()
}) {
Some(package) => flycheck
.restart_for_package(package, target.clone().map(TupleExt::head)),