Implemented that all accounts from message get added to CustomerData

This commit is contained in:
dankl 2020-01-19 17:02:09 +01:00 committed by dankito
parent f55b84032e
commit 69f058b753
1 changed files with 4 additions and 2 deletions

View File

@ -790,8 +790,10 @@ open class FinTsClient @JvmOverloads constructor(
} }
} }
response.getFirstSegmentById<AccountInfo>(InstituteSegmentId.AccountInfo)?.let { accountInfo -> response.getSegmentsById<AccountInfo>(InstituteSegmentId.AccountInfo).forEach { accountInfo ->
if (customer.iban == null && accountInfo.iban != null) {
customer.iban = accountInfo.iban // TODO: remove and use that one from AccountData customer.iban = accountInfo.iban // TODO: remove and use that one from AccountData
}
var accountHolderName = accountInfo.accountHolderName1 var accountHolderName = accountInfo.accountHolderName1
accountInfo.accountHolderName2?.let { accountInfo.accountHolderName2?.let {