Message will be saved when processed by stream

This commit is contained in:
Dmitry 2019-06-27 09:14:16 +03:00
parent 4a99222990
commit ffcf014107
No known key found for this signature in database
GPG Key ID: 4C081485DD21C312
1 changed files with 0 additions and 7 deletions

View File

@ -256,13 +256,6 @@ func (m *Messenger) Send(c Contact, data []byte) error {
}
log.Printf("[Messenger::Send] sent message with hash %x", hash)
message.ID = hash
message.SigPubKey = &m.identity.PublicKey
_, err = m.db.SaveMessages(c, []*protocol.Message{&message})
if err != nil {
return errors.Wrap(err, "failed to save the message")
}
return nil
}