Skip to content

Commit

Permalink
Merge pull request #3 from diorgesl/analysis-Px9jQW
Browse files Browse the repository at this point in the history
Apply fixes from StyleCI
  • Loading branch information
diorgesl authored Oct 1, 2020
2 parents bb13d0a + 9d4990e commit 8e201ee
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions src/Boletos.php
Original file line number Diff line number Diff line change
Expand Up @@ -94,11 +94,11 @@ public function boletos($params = [])
$query = array_merge($query, $params);

try {
$request = $this->client->request( 'GET', $this->uri, [
$request = $this->client->request('GET', $this->uri, [
'query' => $query,
'headers' => [
'Authorization' => 'Bearer '.$this->token,
'Content-type' => 'application/json'
'Content-type' => 'application/json',
],
]);

Expand Down Expand Up @@ -133,14 +133,15 @@ public function registrar(Boleto $boleto)
}
}

public function baixar($id){
public function baixar($id)
{
$boleto = str_pad($id, 10, '0', STR_PAD_LEFT);
try {
$res = $this->client->request('POST', $this->uri.'/'.$this->convenio.$boleto.'/baixar', [
'query' => [
'gw-dev-app-key' => $this->secrets['developer_application_key'],
],
'body' => json_encode(["numeroConvenio" => $this->secrets['numeroConvenio']]),
'body' => json_encode(['numeroConvenio' => $this->secrets['numeroConvenio']]),
'headers' => [
'Authorization' => 'Bearer '.$this->token,
'Content-Type' => 'application/json',
Expand Down

0 comments on commit 8e201ee

Please sign in to comment.