diff --git a/lib/blockchain.js b/lib/blockchain.js index 32fe06e59..7e060ce53 100644 --- a/lib/blockchain.js +++ b/lib/blockchain.js @@ -2,6 +2,7 @@ var mkdirp = require('mkdirp'); var wrench = require('wrench'); var colors = require('colors'); var GethCommands = require('./geth_commands.js'); +var path = require('path'); var Blockchain = function(blockchainConfig, Client) { this.blockchainConfig = blockchainConfig; @@ -54,7 +55,7 @@ Blockchain.prototype.initChainAndGetAddress = function() { mkdirp.sync(this.datadir); // copy mining script - wrench.copyDirSyncRecursive(__dirname + "/../js", ".embark/development/js", {forceDelete: true}); + wrench.copyDirSyncRecursive(path.join(__dirname, "/../js"), ".embark/development/js", {forceDelete: true}); // check if an account already exists, create one if not, return address result = this.runCommand(this.client.listAccountsCommand());