perf(doctor): skip redundant plugin legacy rescans

This commit is contained in:
Vincent Koc
2026-04-14 18:02:18 +01:00
parent 6b2d418973
commit 3362cccc20

View File

@@ -58,13 +58,16 @@ export async function loadAndMaybeMigrateDoctorConfig(params: {
doctorFixCommand,
});
({ cfg, candidate, pendingChanges, fixHints } = legacyStep.state);
const pluginLegacyIssues = findLegacyConfigIssues(
snapshot.parsed,
snapshot.parsed,
listPluginDoctorLegacyConfigRules({
pluginIds: collectRelevantDoctorPluginIds(snapshot.parsed),
}),
);
const pluginLegacyIssues =
snapshot.parsed === snapshot.sourceConfig
? []
: findLegacyConfigIssues(
snapshot.parsed,
snapshot.parsed,
listPluginDoctorLegacyConfigRules({
pluginIds: collectRelevantDoctorPluginIds(snapshot.parsed),
}),
);
const seenLegacyIssues = new Set(
snapshot.legacyIssues.map((issue) => `${issue.path}:${issue.message}`),
);