Skip to content

Commit

Permalink
conditionally
Browse files Browse the repository at this point in the history
  • Loading branch information
zth committed Jun 4, 2024
1 parent 17e23bb commit fb6b95a
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions server/src/server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -235,9 +235,13 @@ let compilerLogsWatcher = chokidar
})
.on("all", (_e, changedPath) => {
if (changedPath.includes("build.ninja")) {
let projectRoot = utils.findProjectRootOfFile(changedPath);
if (projectRoot != null) {
syncProjectConfigCache(projectRoot);
if (
config.extensionConfiguration.cache?.projectConfig?.enabled === true
) {
let projectRoot = utils.findProjectRootOfFile(changedPath);
if (projectRoot != null) {
syncProjectConfigCache(projectRoot);
}
}
} else {
sendUpdatedDiagnostics();
Expand Down

0 comments on commit fb6b95a

Please sign in to comment.