Make sure the active account is always correctly saved to database (#3720)

Fixes #3702
This commit is contained in:
Konrad Pozniak 2023-06-11 20:24:26 +02:00 committed by GitHub
commit 6e06e656b4
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 4 additions and 12 deletions

View file

@ -37,9 +37,11 @@ class AccountManager @Inject constructor(db: AppDatabase) {
@Volatile
var activeAccount: AccountEntity? = null
private set
var accounts: MutableList<AccountEntity> = mutableListOf()
private set
private val accountDao: AccountDao = db.accountDao()
init {