diff options
author | Ben Burwell <ben@benburwell.com> | 2019-07-04 22:34:52 -0400 |
---|---|---|
committer | Ben Burwell <ben@benburwell.com> | 2019-07-04 22:37:29 -0400 |
commit | b46b497f99d7f4dcba8936ce0ebfe8cf982cec1f (patch) | |
tree | b9212d4b196706d3c0e2d93b8dfd8cc39cbacf3b /worker/imap/worker.go | |
parent | 6574dedd8a4afdaedd3677283955a866214bd99a (diff) |
Factor UI models out of the worker message packagemdps1
Before, the information needed to display different parts of the UI was
tightly coupled to the specific messages being sent back and forth to
the backend worker. Separating out a models package allows us to be more
specific about exactly what a backend is able to and required to provide
for the UI.
Diffstat (limited to 'worker/imap/worker.go')
-rw-r--r-- | worker/imap/worker.go | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/worker/imap/worker.go b/worker/imap/worker.go index 78e5537..8d1a5bb 100644 --- a/worker/imap/worker.go +++ b/worker/imap/worker.go @@ -179,9 +179,9 @@ func (w *IMAPWorker) handleImapUpdate(update client.Update) { } w.worker.PostMessage(&types.MessageInfo{ Info: &models.MessageInfo{ - BodyStructure: msg.BodyStructure, - Envelope: msg.Envelope, - Flags: msg.Flags, + BodyStructure: translateBodyStructure(msg.BodyStructure), + Envelope: translateEnvelope(msg.Envelope), + Flags: translateFlags(msg.Flags), InternalDate: msg.InternalDate, Uid: msg.Uid, }, |