diff --git a/lib/remove/rimraf.js b/lib/remove/rimraf.js index d75ad0a1..aa26b047 100644 --- a/lib/remove/rimraf.js +++ b/lib/remove/rimraf.js @@ -297,16 +297,15 @@ function rmkidsSync (p, options) { // try really hard to delete stuff on windows, because it has a // PROFOUNDLY annoying habit of not closing handles promptly when // files are deleted, resulting in spurious ENOTEMPTY errors. - const startTime = Date.now(); + const startTime = Date.now() do { - console.log(Date.now() - startTime); - try { const ret = options.rmdirSync(p, options) return ret } catch (er) { } } while (Date.now() - startTime < 500) // give up after 500ms + } else { const ret = options.rmdirSync(p, options) return ret