Fixed mapping multiple HITANS segments in a message
This commit is contained in:
parent
952fa9c13a
commit
fb70bcd443
|
@ -37,8 +37,9 @@ open class ModelMapper(
|
|||
bank.pinInfo = pinInfo
|
||||
}
|
||||
|
||||
response.getFirstSegmentById<TanInfo>(InstituteSegmentId.TanInfo)?.let { tanInfo ->
|
||||
bank.tanMethodsSupportedByBank = mapToTanMethods(tanInfo)
|
||||
val tanInfos = response.getSegmentsById<TanInfo>(InstituteSegmentId.TanInfo)
|
||||
if (tanInfos.isNotEmpty()) {
|
||||
bank.tanMethodsSupportedByBank = tanInfos.flatMap { tanInfo -> mapToTanMethods(tanInfo) }
|
||||
}
|
||||
|
||||
response.getFirstSegmentById<CommunicationInfo>(InstituteSegmentId.CommunicationInfo)?.let { communicationInfo ->
|
||||
|
|
Loading…
Reference in New Issue