Skip to content

Commit

Permalink
Change for number of clicks.
Browse files Browse the repository at this point in the history
  • Loading branch information
arcshiftsolutions committed Dec 14, 2023
1 parent bf8055c commit a3c45cc
Showing 1 changed file with 1 addition and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,7 @@

import java.security.NoSuchAlgorithmException;
import java.security.SecureRandom;
import java.time.LocalDate;
import java.time.LocalDateTime;
import java.time.format.DateTimeParseException;
import java.util.*;
import java.util.stream.Collectors;

Expand Down Expand Up @@ -755,7 +753,7 @@ public InstituteTypeCode expireUserActivationUrl(UUID userActivationValidationCo
ApiError error = ApiError.builder().timestamp(LocalDateTime.now()).message("Invalid Link Provided").status(BAD_REQUEST).build();
throw new InvalidPayloadException(error);
}
if (activationCodeEntities.stream().anyMatch(el -> el.getNumberOfClicks() >= 2)) {
if (activationCodeEntities.stream().anyMatch(el -> el.getNumberOfClicks() >= 5)) {
ApiError error = ApiError.builder().timestamp(LocalDateTime.now()).message("This User Activation Link has already expired").status(GONE).build();
throw new InvalidPayloadException(error);
}
Expand Down

0 comments on commit a3c45cc

Please sign in to comment.