aboutsummaryrefslogtreecommitdiffstats
path: root/xeth/xeth.go
diff options
context:
space:
mode:
Diffstat (limited to 'xeth/xeth.go')
-rw-r--r--xeth/xeth.go4
1 files changed, 3 insertions, 1 deletions
diff --git a/xeth/xeth.go b/xeth/xeth.go
index dc2d4f06f..06cd9dc1b 100644
--- a/xeth/xeth.go
+++ b/xeth/xeth.go
@@ -79,7 +79,6 @@ func New(eth *eth.Ethereum, frontend Frontend) *XEth {
xeth := &XEth{
backend: eth,
frontend: frontend,
- whisper: NewWhisper(eth.Whisper()),
quit: make(chan struct{}),
filterManager: filter.NewFilterManager(eth.EventMux()),
logQueue: make(map[int]*logQueue),
@@ -88,6 +87,9 @@ func New(eth *eth.Ethereum, frontend Frontend) *XEth {
messages: make(map[int]*whisperFilter),
agent: miner.NewRemoteAgent(),
}
+ if eth.Whisper() != nil {
+ xeth.whisper = NewWhisper(eth.Whisper())
+ }
eth.Miner().Register(xeth.agent)
if frontend == nil {
xeth.frontend = dummyFrontend{}