fix: make error on too many files clear

Fixes #1626
This commit is contained in:
Remy Sharp
2019-11-20 14:12:39 +00:00
parent 3d90879f69
commit 6ccbd66d8c

View File

@@ -96,10 +96,10 @@ function watch() {
});
watcher.on('error', function (error) {
if (error.code === 'EINVAL') {
if (error.code === 'EINVAL' || error.code === 'EMFILE') {
utils.log.error(
'Internal watch failed. Likely cause: too many ' +
'files being watched (perhaps from the root of a drive?\n' +
'files being watched - perhaps from the root of a drive?\n' +
'See https://github.com/paulmillr/chokidar/issues/229 for details'
);
} else {