diff options
author | Felix Lange <fjl@twurst.com> | 2015-04-13 19:39:59 +0800 |
---|---|---|
committer | Felix Lange <fjl@twurst.com> | 2015-04-13 19:39:59 +0800 |
commit | faa2747809ddce7e7b121926ae7dece8fbecae52 (patch) | |
tree | d44594adae244c34ffeff0f0c871f895435a28dd /xeth/whisper.go | |
parent | 61db7a71dd809a003b5c899398b02945c04890c9 (diff) | |
parent | 5467e7b312a29f492ce3063686711ea0bea6dbc3 (diff) | |
download | go-tangerine-faa2747809ddce7e7b121926ae7dece8fbecae52.tar go-tangerine-faa2747809ddce7e7b121926ae7dece8fbecae52.tar.gz go-tangerine-faa2747809ddce7e7b121926ae7dece8fbecae52.tar.bz2 go-tangerine-faa2747809ddce7e7b121926ae7dece8fbecae52.tar.lz go-tangerine-faa2747809ddce7e7b121926ae7dece8fbecae52.tar.xz go-tangerine-faa2747809ddce7e7b121926ae7dece8fbecae52.tar.zst go-tangerine-faa2747809ddce7e7b121926ae7dece8fbecae52.zip |
Merge pull request #690 from karalabe/whisper-cleanup
Whisper cleanup, part 1
Diffstat (limited to 'xeth/whisper.go')
-rw-r--r-- | xeth/whisper.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/xeth/whisper.go b/xeth/whisper.go index 72e1ee04f..51caec8d6 100644 --- a/xeth/whisper.go +++ b/xeth/whisper.go @@ -32,8 +32,8 @@ func (self *Whisper) Post(payload string, to, from string, topics []string, prio pk := crypto.ToECDSAPub(common.FromHex(from)) if key := self.Whisper.GetIdentity(pk); key != nil || len(from) == 0 { msg := whisper.NewMessage(common.FromHex(payload)) - envelope, err := msg.Seal(time.Duration(priority*100000), whisper.Opts{ - Ttl: time.Duration(ttl) * time.Second, + envelope, err := msg.Wrap(time.Duration(priority*100000), whisper.Options{ + TTL: time.Duration(ttl) * time.Second, To: crypto.ToECDSAPub(common.FromHex(to)), From: key, Topics: whisper.TopicsFromString(topics...), |