Skip to content

Commit

Permalink
[NOTASK] fix externalReview ident bug
Browse files Browse the repository at this point in the history
  • Loading branch information
Yannick1712 committed Dec 21, 2024
1 parent d7f8fcb commit cdbfdf3
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/subdomains/generic/kyc/services/kyc.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -516,7 +516,11 @@ export class KycService {
break;

case IdentShortResult.REVIEW:
await this.kycStepRepo.update(...kycStep.externalReview(dto));
if (
![KycStepStatus.INTERNAL_REVIEW, KycStepStatus.MANUAL_REVIEW].includes(kycStep.status) &&
kycStep.getResult() !== dto
)
await this.kycStepRepo.update(...kycStep.externalReview(dto));
break;

case IdentShortResult.SUCCESS:
Expand Down Expand Up @@ -910,7 +914,7 @@ export class KycService {
if (!data.success) errors.push(KycError.INVALID_RESULT);

const userCountry =
identStep.userData.organizationCountry ?? identStep.userData.verifiedCountry ?? identStep.userData.country;
identStep.userData.organizationCountry ?? identStep.userData.verifiedCountry ?? identStep.userData.country;
if (identStep.userData.accountType === AccountType.PERSONAL) {
if (userCountry && !userCountry.dfxEnable) errors.push(KycError.COUNTRY_NOT_ALLOWED);

Expand Down

0 comments on commit cdbfdf3

Please sign in to comment.