Commit 79357a53 authored by Mark Harding's avatar Mark Harding

(fix): email and url still not being provided

1 merge request!420Additional stripe steps and ability to add phone number
Pipeline #102362845 failed with stages
in 44 seconds
......@@ -24,6 +24,10 @@ use Minds\Traits\MagicAttributes;
* @method Account getSSN(): string
* @method Account getPersonalIdNumber(): string
* @method Account getUser(): User
* @method string getEmail()
* @method Account setEmail(string $email)
* @method string getUrl()
* @method Account setUrl(string $url)
*/
class Account
{
......@@ -47,6 +51,9 @@ class Account
/** @var string $email */
private $email;
/** @var string $url */
private $url;
/** @var string $dob */
private $dob;
......
......@@ -81,6 +81,14 @@ class Manager
$data['individual']['gender'] = $account->getGender();
}
if ($account->getEmail()) {
$data['individual']['email'] = $account->getEmail();
}
if ($account->getUrl()) {
$data['business_profile']['url'] = $account->getUrl();
}
if ($account->getPhoneNumber()) {
$data['individual']['phone'] = "+" . $account->getPhoneNumber();
}
......
......@@ -64,6 +64,10 @@ class ManagerSpec extends ObjectBehavior
->willReturn(null);
$account->getPersonalIdNumber()
->willReturn(null);
$account->getEmail()
->willReturn('test@minds.com');
$account->getUrl()
->willReturn('https://minds.com/test');
$this->accountInstance->create(Argument::any())
->shouldBeCalled()
......
Please register or to comment