Skip to content

Commit

Permalink
walletnode: use same prefix as plugin when running own wallet node (#435
Browse files Browse the repository at this point in the history
)
  • Loading branch information
chikeichan authored Jan 6, 2022
1 parent c663f99 commit d92e3b4
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions app/background/wallet/service.js
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ class WalletService {
});

// This is an unfortunate work-around for the fact that
// WalletNode doesn't accept a `nodePath` option to
// WalletNode doesn't accept a `nodePath` option to
// pass to NodeClient which gets passed to bcurl/client.
const nodeURL =
this.conn.pathname
Expand All @@ -167,6 +167,8 @@ class WalletService {
:
null;

const prefix = await nodeService.getDir();

this.node = new WalletNode({
network: this.networkName,
nodeHost: this.conn.host,
Expand All @@ -176,7 +178,7 @@ class WalletService {
nodeURL,
apiKey: this.walletApiKey,
memory: false,
prefix: HSD_DATA_DIR,
prefix: prefix,
logFile: true,
logConsole: false,
logLevel: 'debug',
Expand Down

0 comments on commit d92e3b4

Please sign in to comment.