diff --git a/lib/Tor.js b/lib/Tor.js index 824ff71..d7083da 100644 --- a/lib/Tor.js +++ b/lib/Tor.js @@ -73,7 +73,7 @@ const Tor = (function () { function ($next) { temp.open('txt',function (err, file) { if (file) { - fs.write(file.fd, shell.cat(process.cwd()+'/config/torrc')); + fs.write(file.fd, shell.cat(__dirname'/../config/torrc')); fs.close(file.fd) } $next(err, (file && file.path)); diff --git a/lib/hosts.js b/lib/hosts.js index 284b0a2..70bf08e 100644 --- a/lib/hosts.js +++ b/lib/hosts.js @@ -1,5 +1,5 @@ const shell = require('shelljs'); -const HOSTS = shell.cat(process.cwd()+'/config/hosts') +const HOSTS = shell.cat(__dirname+'/../config/hosts') .split("\n") .filter((host) => (host[0] !== '#') && host.trim().length) .map((line) => line.split(' '));