Skip to content

Commit

Permalink
Adding complement parameter on Address' constructor
Browse files Browse the repository at this point in the history
  • Loading branch information
alvescleiton committed May 31, 2017
1 parent 74684c6 commit 6bf5b3f
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/ClearSale/XmlEntity/SendOrder/Address.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ class Address implements XmlEntityInterface
private $zipCode;
private $reference;

public static function create($street, $number, $county, $country, $city, $state, $zipCode)
public static function create($street, $number, $county, $country, $city, $state, $zipCode, $complement = '')
{
$instance = new self();

Expand All @@ -31,6 +31,10 @@ public static function create($street, $number, $county, $country, $city, $state
$instance->setState($state);
$instance->setZipCode($zipCode);

if (!empty($complement)) {
$instance->setComplement($complement);
}

return $instance;
}

Expand Down

0 comments on commit 6bf5b3f

Please sign in to comment.