File tree Expand file tree Collapse file tree 2 files changed +2
-7
lines changed Expand file tree Collapse file tree 2 files changed +2
-7
lines changed Original file line number Diff line number Diff line change @@ -1492,8 +1492,6 @@ export let sys: System = (() => {
1492
1492
from ?( input : string , encoding ?: string ) : any ;
1493
1493
} = require ( "buffer" ) . Buffer ;
1494
1494
1495
- const nodeVersion = getNodeMajorVersion ( ) ;
1496
- const isNode4OrLater = nodeVersion ! >= 4 ;
1497
1495
const isLinuxOrMacOs = process . platform === "linux" || process . platform === "darwin" ;
1498
1496
1499
1497
const platform : string = _os . platform ( ) ;
@@ -1507,7 +1505,7 @@ export let sys: System = (() => {
1507
1505
// Note that if we ever emit as files like cjs/mjs, this check will be wrong.
1508
1506
const executingFilePath = __filename . endsWith ( "sys.js" ) ? _path . join ( _path . dirname ( __dirname ) , "__fake__.js" ) : __filename ;
1509
1507
1510
- const fsSupportsRecursiveFsWatch = isNode4OrLater && ( process . platform === "win32" || process . platform === "darwin" ) ;
1508
+ const fsSupportsRecursiveFsWatch = process . platform === "win32" || process . platform === "darwin" ;
1511
1509
const getCurrentDirectory = memoize ( ( ) => process . cwd ( ) ) ;
1512
1510
const { watchFile, watchDirectory } = createSystemWatchFunctions ( {
1513
1511
pollingWatchFileWorker : fsWatchFileWorker ,
Original file line number Diff line number Diff line change @@ -11,7 +11,6 @@ import {
11
11
DirectoryWatcherCallback ,
12
12
FileWatcher ,
13
13
getDirectoryPath ,
14
- getNodeMajorVersion ,
15
14
getRootLength ,
16
15
JsTyping ,
17
16
LanguageServiceMode ,
@@ -299,9 +298,7 @@ export function initializeNodeSystem(): StartInput {
299
298
300
299
const libDirectory = getDirectoryPath ( normalizePath ( sys . getExecutingFilePath ( ) ) ) ;
301
300
302
- const nodeVersion = getNodeMajorVersion ( ) ;
303
- // use watchGuard process on Windows when node version is 4 or later
304
- const useWatchGuard = process . platform === "win32" && nodeVersion ! >= 4 ;
301
+ const useWatchGuard = process . platform === "win32" ;
305
302
const originalWatchDirectory : ServerHost [ "watchDirectory" ] = sys . watchDirectory . bind ( sys ) ;
306
303
const logger = createLogger ( ) ;
307
304
You can’t perform that action at this time.
0 commit comments