1
0
Fork 0
mirror of https://github.com/pgpainless/pgpainless.git synced 2024-11-05 03:55:58 +01:00

Throw away older certifications in map constructor of CertificationSet

This commit is contained in:
Paul Schaub 2023-07-05 17:24:40 +02:00
parent a6955eb81a
commit 41f4e3c453
Signed by: vanitasvitae
GPG key ID: 62BEE9264BF17311

View file

@ -21,7 +21,11 @@ class CertificationSet(
certifications: Map<String?, List<Certification>>) {
init {
certifications.forEach { (t, u) -> _certifications[t] = u.toMutableList() }
certifications.forEach { (_, certifications) ->
certifications.forEach {
add(it)
}
}
}
private val _certifications: MutableMap<String?, MutableList<Certification>> = mutableMapOf()