Fixed iterating over banks so that ForEach is able to handle dynamic changes (e.g. when an account got added)

This commit is contained in:
dankito 2020-07-31 00:28:03 +02:00
parent 341b68fec1
commit 338995e671
1 changed files with 2 additions and 2 deletions

View File

@ -15,8 +15,8 @@ struct AccountsTab: View {
Form {
AllBanksListItem(banks: data.banks)
ForEach(0 ..< data.banks.count) { bankIndex in
BankListItem(bank: self.data.banks[bankIndex])
ForEach(data.banks) { bank in
BankListItem(bank: bank)
}
}
}