Remove maximum denial tracking.

This commit is contained in:
Alex Hart
2023-08-09 09:56:29 -03:00
parent c479dd404c
commit 3c9004d87d
2 changed files with 1 additions and 25 deletions

View File

@@ -21,10 +21,6 @@ data class PendingParticipantCollection(
private val nowProvider: () -> Duration = { System.currentTimeMillis().milliseconds }
) {
companion object {
private val MAX_DENIALS = 2
}
/**
* Creates a new collection with the given recipients applied to it with the following rules:
*
@@ -47,7 +43,7 @@ data class PendingParticipantCollection(
val newEntryMap = (participantMap + newEntries)
.filterNot { it.value.state == State.PENDING && it.key !in submittedIdSet }
.mapValues {
if (it.value.state == State.DENIED && it.key in submittedIdSet && it.value.denialCount < MAX_DENIALS) {
if (it.value.state == State.DENIED && it.key in submittedIdSet) {
it.value.copy(state = State.PENDING, stateChangeAt = now)
} else {
it.value