Skip to content

Commit

Permalink
1.1.7 Check API key before creating a shipment
Browse files Browse the repository at this point in the history
  • Loading branch information
Reindert committed Jul 17, 2017
1 parent 58a234b commit 5d94058
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/Model/MyParcelRequest.php
Original file line number Diff line number Diff line change
Expand Up @@ -198,6 +198,7 @@ public function sendRequest($method = 'POST', $uri = self::REQUEST_TYPE_SHIPMENT
$request->close();

if ($this->getError()) {
throw new \Exception('Error in MyParcel API request: ' . $this->getError() . ' Url: ' . $url . ' Request: ' . $this->body);
}

return $this;
Expand Down

0 comments on commit 5d94058

Please sign in to comment.