diff --git a/lib/cache_fs.js b/lib/cache_fs.js index 28cb43e..3daf473 100644 --- a/lib/cache_fs.js +++ b/lib/cache_fs.js @@ -54,14 +54,16 @@ class CacheFS { if (fix) { try { var stat = fs.statSync(path); - if (stat.isDirectory()) + if (stat.isDirectory()) { fs.rmdirSync(path); - else + helpers.log(consts.LOG_DBG, msg + " Directory deleted."); + } else { fs.unlinkSync(path); - helpers.log(consts.LOG_DBG, msg + " File deleted."); + helpers.log(consts.LOG_DBG, msg + " File deleted."); + } } catch (err) { - helpers.log(consts.LOG_DBG, err); + helpers.log(consts.LOG_ERR, err); } } else {