diff --git a/registration-processor/core-processor/registration-processor-uin-generator-stage/src/main/java/io/mosip/registration/processor/stages/uingenerator/stage/UinGeneratorStage.java b/registration-processor/core-processor/registration-processor-uin-generator-stage/src/main/java/io/mosip/registration/processor/stages/uingenerator/stage/UinGeneratorStage.java index 37ccce8e732..a14470e0a58 100644 --- a/registration-processor/core-processor/registration-processor-uin-generator-stage/src/main/java/io/mosip/registration/processor/stages/uingenerator/stage/UinGeneratorStage.java +++ b/registration-processor/core-processor/registration-processor-uin-generator-stage/src/main/java/io/mosip/registration/processor/stages/uingenerator/stage/UinGeneratorStage.java @@ -278,7 +278,7 @@ public MessageDTO process(MessageDTO object) { demographicIdentity.put("UIN", uinField); idResponseDTO = sendIdRepoWithUin(registrationId, registrationStatusDto.getRegistrationType(), demographicIdentity, uinField, description); - if ((idResponseDTO.getErrors() != null && !idResponseDTO.getErrors().isEmpty()) && idResponseDTO + if (idResponseDTO.getErrors() != null && !idResponseDTO.getErrors().isEmpty() && idResponseDTO .getErrors().get(0).getErrorCode().equalsIgnoreCase(INVALID_INPUT_PARAMETER_ERROR_CODE)) { for (int i = 0; i < maxRetrycount; i++) { regProcLogger.info(StatusUtil.INVALID_INPUT_PARAMETER.getMessage()+":"+StatusUtil.INVALID_INPUT_PARAMETER.getCode()+", Retrying "+(i+1)+" times"); @@ -290,7 +290,7 @@ public MessageDTO process(MessageDTO object) { idResponseDTO = sendIdRepoWithUin(registrationId, registrationStatusDto.getRegistrationType(), demographicIdentity, uinField, description); - if ((idResponseDTO.getErrors() == null || idResponseDTO.getErrors().isEmpty()) + if (idResponseDTO.getErrors() == null || idResponseDTO.getErrors().isEmpty() || idResponseDTO.getErrors().get(0) .getErrorCode() != INVALID_INPUT_PARAMETER_ERROR_CODE) break;