diff --git a/index.js b/index.js index a427caf..9dcc056 100644 --- a/index.js +++ b/index.js @@ -8,7 +8,7 @@ exports = module.exports = core = {}; core.version = (JSON.parse(fs.readFileSync(__dirname + '/package.json')).version); core.create_dir = function() { - if (!path.existsSync(kpath)) { + if (!fs.existsSync(kpath)) { fs.mkdir(kpath, 0755, function(err) { if (err) throw err; }); diff --git a/test.js b/test.js index 80cf05d..e043c64 100644 --- a/test.js +++ b/test.js @@ -8,7 +8,7 @@ var kotoba_file = __dirname + '/.kotoba/' + kotoba.file_name() + '.kotoba' , kotoba_file1 = __dirname + '/.kotoba/' + (kotoba.file_name() - 1) + '.kotoba'; var exists = function() { - return path.existsSync(kotoba_file); + return fs.existsSync(kotoba_file); } var capture_stdout = function(cmd, callback) {