Skip to content

Commit

Permalink
Remove redundant function
Browse files Browse the repository at this point in the history
  • Loading branch information
atoff authored Jan 3, 2018
1 parent 6f290ac commit 722f3f4
Showing 1 changed file with 0 additions and 21 deletions.
21 changes: 0 additions & 21 deletions src/Weather/Metar.php
Original file line number Diff line number Diff line change
Expand Up @@ -231,27 +231,6 @@ public function flight_cat()
return (string) $this->raw_array->flight_category;
}

private function sendRequest($params = [])
{
$params['format'] = "xml";

try {
$client = new Client(['verify' => false]);
$result = $client->get($this->base_url, [
'query' => $params
]);
$content = $result->getBody()->getContents();
$statuscode = $result->getStatusCode();
if (200 !== $statuscode) {
// Unable to retrieve weather data
return false;
}
} catch (\Exception $e) {
return false;
}
return $content;
}

public function toArray()
{
$exclude_functions = [
Expand Down

0 comments on commit 722f3f4

Please sign in to comment.