Fixed crash
This commit is contained in:
parent
5d048ee6db
commit
f6bb1ab066
1 changed files with 3 additions and 1 deletions
|
@ -46,7 +46,9 @@ class AccountSettingsViewModelFactory(private val identity: String) :
|
||||||
if (defaultAccount != null) {
|
if (defaultAccount != null) {
|
||||||
return AccountSettingsViewModel(defaultAccount) as T
|
return AccountSettingsViewModel(defaultAccount) as T
|
||||||
}
|
}
|
||||||
return coreContext.core.accountList.firstOrNull() as T
|
|
||||||
|
val firstAccount = coreContext.core.accountList.first()
|
||||||
|
return AccountSettingsViewModel(firstAccount) as T
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue