Skip to content

Commit

Permalink
LegalUserHelper: ask validation after file upload
Browse files Browse the repository at this point in the history
  • Loading branch information
alexislefebvre authored and Alexis Lefebvre committed Apr 11, 2019
1 parent 22f4bf2 commit aa19253
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion Helper/User/LegalUserHelper.php
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,6 @@ protected function createDocument($fileContent, UserInterface $user, $type)
$kycDocument = new KycDocument();
$kycDocument->UserId = $user->getMangoUserId();
$kycDocument->Type = $type;
$kycDocument->Status = KycDocumentStatus::ValidationAsked;

$document = $this->mangopayHelper->Users->CreateKycDocument($user->getMangoUserId(), $kycDocument);

Expand All @@ -181,6 +180,9 @@ protected function createDocument($fileContent, UserInterface $user, $type)

$this->mangopayHelper->Users->CreateKycPage($user->getMangoUserId(), $document->Id, $page);

$document->Status = KycDocumentStatus::ValidationAsked;

$this->mangopayHelper->Users->UpdateKycDocument($user->getMangoUserId(), $document);

return $document;
}
Expand Down

0 comments on commit aa19253

Please sign in to comment.