Fixed setting displayIndex only if adding account was successful

This commit is contained in:
dankito 2020-09-20 15:59:44 +02:00
parent 129b4f64fa
commit 63caf84894
1 changed files with 3 additions and 3 deletions

View File

@ -148,10 +148,10 @@ open class BankingPresenter(
val startDate = Date()
newClient.addAccountAsync { response ->
val account = response.customer
account.displayIndex = customers.size
if (response.successful) {
val account = response.customer
account.displayIndex = customers.size
addClientForAccount(account, newClient)
selectedAccount(account)