diff options
author | Drew DeVault <sir@cmpwn.com> | 2019-05-20 19:20:20 -0400 |
---|---|---|
committer | Drew DeVault <sir@cmpwn.com> | 2019-05-20 19:28:04 -0400 |
commit | 2dc436555d8bfa6f2409173d87cd0fec2b2385cf (patch) | |
tree | 73e589fc1ff64fa5f4362a9500a739703ea6a27c /widgets | |
parent | cc90cd21610e7c78bc2cd9b04840fa1266617e6f (diff) | |
download | aerc-2dc436555d8bfa6f2409173d87cd0fec2b2385cf.tar.gz |
Load IMAP worker for imap+insecure
Diffstat (limited to 'widgets')
-rw-r--r-- | widgets/account.go | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/widgets/account.go b/widgets/account.go index 4ccb43d..bd47f46 100644 --- a/widgets/account.go +++ b/widgets/account.go @@ -37,7 +37,8 @@ func NewAccountView(conf *config.AercConfig, acct *config.AccountConfig, worker, err := worker.NewWorker(acct.Source, logger) if err != nil { - host.SetStatus(fmt.Sprintf("%s: %s", acct.Name, err)) + host.SetStatus(fmt.Sprintf("%s: %s", acct.Name, err)). + Color(tcell.ColorDefault, tcell.ColorRed) return &AccountView{ acct: acct, grid: grid, @@ -74,6 +75,9 @@ func NewAccountView(conf *config.AercConfig, acct *config.AccountConfig, } func (acct *AccountView) Tick() bool { + if acct.worker == nil { + return false + } select { case msg := <-acct.worker.Messages: msg = acct.worker.ProcessMessage(msg) |