fix bug where db was being created in the core directory

removed the __dirname from db.js