From c670664d0c5d40ce2977d952b9f9ec2ef7840e9c Mon Sep 17 00:00:00 2001 From: Jonathan Cammisuli Date: Fri, 17 May 2024 11:09:12 -0400 Subject: [PATCH] fix(core): only check for `err` in `handleWorkspaceChanges` Fixes #23031 --- packages/nx/src/daemon/server/server.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/nx/src/daemon/server/server.ts b/packages/nx/src/daemon/server/server.ts index 3e5552122b629..0aa1766158478 100644 --- a/packages/nx/src/daemon/server/server.ts +++ b/packages/nx/src/daemon/server/server.ts @@ -298,7 +298,7 @@ const handleWorkspaceChanges: FileWatcherCallback = async ( return; } - if (err || !changeEvents || !changeEvents.length) { + if (err) { let error = typeof err === 'string' ? new Error(err) : err; serverLogger.watcherLog( 'Unexpected workspace watcher error',