Skip to content

Commit

Permalink
Allow source parameter in customer update request
Browse files Browse the repository at this point in the history
  • Loading branch information
jsampedro77 committed Jun 9, 2017
1 parent c9a575f commit 2679dba
Showing 1 changed file with 25 additions and 0 deletions.
25 changes: 25 additions & 0 deletions src/Message/UpdateCustomerRequest.php
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,27 @@ public function setEmail($value)
return $this->setParameter('email', $value);
}

/**
* Get the customer's source.
*
* @return string
*/
public function getSource()
{
return $this->getParameter('source');
}

/**
* Sets the customer's source.
*
* @param string $value
* @return CreateCustomerRequest provides a fluent interface.
*/
public function setSource($value)
{
$this->setParameter('source', $value);
}

public function getData()
{
$this->validate('customerReference');
Expand All @@ -77,6 +98,10 @@ public function getData()
$data['metadata'] = $this->getMetadata();
}

if ($this->getSource()) {
$data['source'] = $this->getSource();
}

return $data;
}

Expand Down

0 comments on commit 2679dba

Please sign in to comment.