@@ -149,7 +149,7 @@ |
||
149 | 149 | |
150 | 150 | /** |
151 | 151 | * Set accept |
152 | - * @param array|string $accept |
|
152 | + * @param string $accept |
|
153 | 153 | * @return AbstractApi |
154 | 154 | */ |
155 | 155 | public function setAccept($accept): AbstractApi { |
@@ -460,7 +460,7 @@ discard block |
||
460 | 460 | break; |
461 | 461 | } |
462 | 462 | |
463 | - $curl->success(function (CurlClient $instance) { |
|
463 | + $curl->success(function(CurlClient $instance) { |
|
464 | 464 | $this->headers = $instance->getHeaders(); |
465 | 465 | $this->success = $instance->getResponse(); |
466 | 466 | $data = json_decode($this->success, true); |
@@ -468,7 +468,7 @@ discard block |
||
468 | 468 | $this->success = $data; |
469 | 469 | } |
470 | 470 | }); |
471 | - $curl->error(function (CurlClient $instance) { |
|
471 | + $curl->error(function(CurlClient $instance) { |
|
472 | 472 | $this->headers = $instance->getHeaders(); |
473 | 473 | $this->failure = $instance->getResponse(); |
474 | 474 | $data = json_decode($this->failure, true); |
@@ -378,8 +378,7 @@ discard block |
||
378 | 378 | CURLOPT_HTTPAUTH => CURLAUTH_BASIC, |
379 | 379 | CURLOPT_USERPWD => $this->getHttpAuth()['username'] |
380 | 380 | ]); |
381 | - } |
|
382 | - else { |
|
381 | + } else { |
|
383 | 382 | $curl->setOption([ |
384 | 383 | CURLOPT_HTTPAUTH => CURLAUTH_BASIC, |
385 | 384 | CURLOPT_USERPWD => sprintf('%s:%s', $this->getHttpAuth()['username'], $this->getHttpAuth()['password']) |
@@ -502,8 +501,7 @@ discard block |
||
502 | 501 | throw new Exception('Too few arguments, missing argument: ' . $key); |
503 | 502 | } |
504 | 503 | $replaces[] = $params[$key]; |
505 | - } |
|
506 | - else { |
|
504 | + } else { |
|
507 | 505 | if (!array_key_exists($value, $params[0])) { |
508 | 506 | throw new Exception('Missing array argument: ' . $key); |
509 | 507 | } |
@@ -152,7 +152,7 @@ |
||
152 | 152 | * @param array $labels |
153 | 153 | * @return array |
154 | 154 | */ |
155 | - public function createIssue(string $title, string $body = '', string $assignee = '', int $milestone = 0, array $labels = []): array { |
|
155 | + public function createIssue(string $title, string $body = '', string $assignee = '', int $milestone = 0, array $labels = []): array { |
|
156 | 156 | return $this->getApi()->request( |
157 | 157 | $this->getApi()->sprintf('/repos/:owner/:repo/issues', $this->getOwner(), $this->getRepo()), |
158 | 158 | Request::METHOD_POST, |