diff --git a/lib/db/json.js b/lib/db/json.js index 376a2a791cae9a968949a202772df5c2193d552f..08bd09d2193c4f8d7e1ee5b0fa379f31eb9baf6d 100644 --- a/lib/db/json.js +++ b/lib/db/json.js @@ -59,7 +59,7 @@ function flush() { function sync() { // the database not existing yet just means its empty, don't log an error - if (path.existsSync(dbPath)) { + if (fs.existsSync(dbPath)) { try { db = JSON.parse(fs.readFileSync(dbPath)); diff --git a/lib/i18n.js b/lib/i18n.js index 7b2d214d96838f943392f4c7646419f91c35660b..08c9ff7a4e6ca29047520839a4b0c7dfdbc3edc7 100644 --- a/lib/i18n.js +++ b/lib/i18n.js @@ -66,8 +66,8 @@ exports.abide = function (options) { default_locale = localeFrom(options.default_lang); mo_cache[l] = { - mo_exists: path.existsSync(mo_file_path(l)), - json_exists: path.existsSync(json_file_path(l)), + mo_exists: fs.existsSync(mo_file_path(l)), + json_exists: fs.existsSync(json_file_path(l)), gt: null }; if (l !== debug_locale) { diff --git a/lib/logging.js b/lib/logging.js index 058d161869a7e3113ef506304a6f8b81e16e8c0e..4472cc2484838d443e22ace764d6f8bd1c9d1cf9 100644 --- a/lib/logging.js +++ b/lib/logging.js @@ -25,7 +25,7 @@ var log_path = path.join(configuration.get('var_path'), 'log'); // simple inline function for creation of dirs function mkdir_p(p) { - if (!path.existsSync(p)) { + if (!fs.existsSync(p)) { mkdir_p(path.dirname(p)); fs.mkdirSync(p, "0755"); } diff --git a/lib/metrics.js b/lib/metrics.js index 48134aa5f4bd1feee13b39e23a90cd9e1a330fc5..6b3f21b519447a2acd3a04efb9593ef428cbe9e6 100644 --- a/lib/metrics.js +++ b/lib/metrics.js @@ -33,7 +33,7 @@ var LOGGER; // simple inline function for creation of dirs function mkdir_p(p) { - if (!path.existsSync(p)) { + if (!fs.existsSync(p)) { mkdir_p(path.dirname(p)); fs.mkdirSync(p, "0755"); }