Skip to content

Commit

Permalink
Fix PHPDoc and a dry run parameter for generateLabel
Browse files Browse the repository at this point in the history
  • Loading branch information
gaelreyrol committed Jan 3, 2019
1 parent 3b71de8 commit 9348295
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 8 deletions.
2 changes: 1 addition & 1 deletion src/ParcelTracking.php
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ public function __construct(array $credentials, array $options = array())
* @return ParcelStatus
* @throws \Exception
*/
public function getStatusByID($id, $options = array())
public function getStatusByID(string $id, array $options = array())
{
$options = array_merge(
array(
Expand Down
15 changes: 8 additions & 7 deletions src/Postage.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,20 +20,21 @@ class Postage extends Client
*
* @throws \Exception
*/
public function __construct($credentials, $options = array())
public function __construct(array $credentials, array $options = array())
{
parent::__construct($credentials, self::SERVICE_URL, $options);
}

/**
* @param string $outputFormat ToDo
* @param string $letter ToDo
* @param array $options Additional parameters
*
* @param array $outputFormat ToDo
* @param array $letter ToDo
* @param bool $check Perform dry run instead of real method usage
* @param array $options Additional parameters
*
* @return Object
* @throws \Exception
*/
public function generateLabel($outputFormat, $letter, $options = array())
public function generateLabel(array $outputFormat, array $letter, bool $check = false, $options = array())
{
$options = array_merge(
array(
Expand All @@ -44,7 +45,7 @@ public function generateLabel($outputFormat, $letter, $options = array())
);

$result = $this->soapExec(
'generateLabel',
($check) ? 'checkGenerateLabel' : 'generateLabel',
$options
);

Expand Down

1 comment on commit 9348295

@gaelreyrol
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

#2

Please sign in to comment.