From c179797ce5d26dd02af91379e278ee9b7592d681 Mon Sep 17 00:00:00 2001 From: RyanZim Date: Tue, 25 Apr 2017 09:42:13 -0400 Subject: [PATCH] Add else block to throw error from catch in removeSync() --- lib/remove/rimraf.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/remove/rimraf.js b/lib/remove/rimraf.js index 141a82d2..2f4bb7e7 100644 --- a/lib/remove/rimraf.js +++ b/lib/remove/rimraf.js @@ -281,6 +281,8 @@ function rmdirSync (p, options, originalEr) { throw originalEr } else if (er.code === 'ENOTEMPTY' || er.code === 'EEXIST' || er.code === 'EPERM') { rmkidsSync(p, options) + } else { + throw er } } }