Skip to content

Commit

Permalink
Добавлена проверка на ошибку curl
Browse files Browse the repository at this point in the history
  • Loading branch information
visavi committed Nov 3, 2018
1 parent a6416e5 commit 46a817a
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/Rzd/Query.php
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,10 @@ public function send($path, array $params = [], $method = 'post'): Curl
$this->curl->setCookieJar($cookieFile);
$this->run($path, $params, $method);

if ($this->curl->error) {
throw new RuntimeException($this->curl->errorMessage);
}

return $this->curl;
}

Expand Down

0 comments on commit 46a817a

Please sign in to comment.