Handle bad acctList settings

develop
knotteye 2021-04-25 15:06:00 -05:00
parent 4b55caca87
commit 4560215d7a
1 changed files with 9 additions and 3 deletions

View File

@ -200,9 +200,15 @@ class App(QMainWindow):
if not acctList:
self.newAcctDialog()
return
for acct in acctList:
CallThread(getAvi, None, acct['instance'])
self.initAcct(acct['instance'], acct['username'])
for ind in range(0,len(acctList)):
CallThread(getAvi, None, acctList[ind]['instance'])
try:
self.initAcct(acctList[ind]['instance'], acctList[ind]['username'])
except:
print("account info corrupted, deleting")
del acctList[ind]
if acctList:
self.settings.setValue('acctList', acctList)
def systrayClicked(self, reason):
if reason == QSystemTrayIcon.Trigger: