Fix always showing last account tab

This commit is contained in:
Drew DeVault 2019-05-22 10:39:52 -04:00
parent 4d6e665204
commit a7341aff21

View file

@ -56,8 +56,8 @@ func NewAerc(conf *config.AercConfig, logger *log.Logger,
tabs: tabs,
}
for _, acct := range conf.Accounts {
view := NewAccountView(conf, &acct, logger, aerc)
for i, acct := range conf.Accounts {
view := NewAccountView(conf, &conf.Accounts[i], logger, aerc)
aerc.accounts[acct.Name] = view
tabs.Add(view, acct.Name)
}