mirror of
https://github.com/microsoft/TypeScript.git
synced 2026-02-15 11:35:42 -06:00
Fix the error callback of the present directory watcher
This commit is contained in:
parent
e248d08e4c
commit
f6f465280d
@ -291,12 +291,11 @@ namespace ts {
|
||||
callback
|
||||
);
|
||||
dirWatcher.on("error", () => {
|
||||
if (!directoryExists(directoryName)) {
|
||||
// Deleting directory
|
||||
watcher = watchMissingDirectory();
|
||||
// Call the callback for current directory
|
||||
callback("rename", "");
|
||||
}
|
||||
// Watch the missing directory
|
||||
watcher.close();
|
||||
watcher = watchMissingDirectory();
|
||||
// Call the callback for current directory
|
||||
callback("rename", "");
|
||||
});
|
||||
return dirWatcher;
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user