Skip to content

Commit 6d4870f

Browse files
whisper -- canonicalHost, defaultHost
1 parent f91baf7 commit 6d4870f

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

lib/modules/whisper/index.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@ let utils = require('../../utils/utils.js');
22
let fs = require('../../core/fs.js');
33
let Web3 = require('web3');
44

5+
const {canonicalHost, defaultHost} = require('../../utils/host');
6+
57
class Whisper {
68

79
constructor(embark, _options) {
@@ -69,7 +71,7 @@ class Whisper {
6971
let connection = this.communicationConfig.connection || {};
7072
// todo: make the add code a function as well
7173
let config = JSON.stringify({
72-
server: connection.host || 'localhost',
74+
server: canonicalHost(connection.host || defaultHost),
7375
port: connection.port || '8546',
7476
type: connection.type || 'ws'
7577
});

0 commit comments

Comments
 (0)