@@ -1,4 +1,4 @@ |
||
1 | -<?php declare(strict_types=1); |
|
1 | +<?php declare(strict_types = 1); |
|
2 | 2 | |
3 | 3 | |
4 | 4 | namespace ExileeD\Inoreader\Objects; |
@@ -1,4 +1,4 @@ discard block |
||
1 | -<?php declare(strict_types=1); |
|
1 | +<?php declare(strict_types = 1); |
|
2 | 2 | |
3 | 3 | |
4 | 4 | namespace ExileeD\Inoreader\Objects; |
@@ -49,10 +49,10 @@ discard block |
||
49 | 49 | public function items(): array |
50 | 50 | { |
51 | 51 | |
52 | - $items = []; |
|
52 | + $items = [ ]; |
|
53 | 53 | |
54 | 54 | foreach ($this->data->items as $item) { |
55 | - $items[] = new Item($item); |
|
55 | + $items[ ] = new Item($item); |
|
56 | 56 | } |
57 | 57 | |
58 | 58 | return $items; |
@@ -1,4 +1,4 @@ |
||
1 | -<?php declare(strict_types=1); |
|
1 | +<?php declare(strict_types = 1); |
|
2 | 2 | |
3 | 3 | |
4 | 4 | namespace ExileeD\Inoreader\Objects; |
@@ -1,4 +1,4 @@ discard block |
||
1 | -<?php declare(strict_types=1); |
|
1 | +<?php declare(strict_types = 1); |
|
2 | 2 | |
3 | 3 | |
4 | 4 | namespace ExileeD\Inoreader\Client; |
@@ -22,7 +22,7 @@ discard block |
||
22 | 22 | * @throws InoreaderException |
23 | 23 | * @return ResponseInterface |
24 | 24 | */ |
25 | - public function get($endpoint, $params = [], $headers = []): ResponseInterface; |
|
25 | + public function get($endpoint, $params = [ ], $headers = [ ]): ResponseInterface; |
|
26 | 26 | |
27 | 27 | /** |
28 | 28 | * Make an HTTP POST request to API |
@@ -36,7 +36,7 @@ discard block |
||
36 | 36 | * @throws InoreaderException |
37 | 37 | * @return ResponseInterface |
38 | 38 | */ |
39 | - public function post($endpoint, $params = [], $headers = []): ResponseInterface; |
|
39 | + public function post($endpoint, $params = [ ], $headers = [ ]): ResponseInterface; |
|
40 | 40 | |
41 | 41 | |
42 | 42 | /** |
@@ -52,7 +52,7 @@ discard block |
||
52 | 52 | * @throws InoreaderException |
53 | 53 | * @return ResponseInterface |
54 | 54 | */ |
55 | - public function request($endpoint, $params = [], $method = 'GET', array $headers = []): ResponseInterface; |
|
55 | + public function request($endpoint, $params = [ ], $method = 'GET', array $headers = [ ]): ResponseInterface; |
|
56 | 56 | |
57 | 57 | |
58 | 58 | /** |
@@ -1,4 +1,4 @@ discard block |
||
1 | -<?php declare(strict_types=1); |
|
1 | +<?php declare(strict_types = 1); |
|
2 | 2 | |
3 | 3 | namespace ExileeD\Inoreader\Client; |
4 | 4 | |
@@ -39,7 +39,7 @@ discard block |
||
39 | 39 | return $this->options[ 'base_uri' ]; |
40 | 40 | } |
41 | 41 | |
42 | - public function get($endpoint, $params = [], $headers = []): ResponseInterface |
|
42 | + public function get($endpoint, $params = [ ], $headers = [ ]): ResponseInterface |
|
43 | 43 | { |
44 | 44 | $query = [ |
45 | 45 | 'query' => $params, |
@@ -51,7 +51,7 @@ discard block |
||
51 | 51 | /** |
52 | 52 | * @inheritdoc |
53 | 53 | */ |
54 | - public function request($endpoint, $params = [], $method = 'GET', array $headers = []): ResponseInterface |
|
54 | + public function request($endpoint, $params = [ ], $method = 'GET', array $headers = [ ]): ResponseInterface |
|
55 | 55 | { |
56 | 56 | |
57 | 57 | $options = array_merge($params, [ |
@@ -83,7 +83,7 @@ discard block |
||
83 | 83 | $this->client = $client; |
84 | 84 | } |
85 | 85 | |
86 | - public function post($endpoint, $params = [], $headers = []): ResponseInterface |
|
86 | + public function post($endpoint, $params = [ ], $headers = [ ]): ResponseInterface |
|
87 | 87 | { |
88 | 88 | |
89 | 89 | $body = [ |
@@ -1,4 +1,4 @@ discard block |
||
1 | -<?php declare(strict_types=1); |
|
1 | +<?php declare(strict_types = 1); |
|
2 | 2 | |
3 | 3 | namespace ExileeD\Inoreader; |
4 | 4 | |
@@ -39,7 +39,7 @@ discard block |
||
39 | 39 | * @throws InoreaderException |
40 | 40 | * @return \stdClass |
41 | 41 | */ |
42 | - public function post(string $endpoint, $params = []): \stdClass |
|
42 | + public function post(string $endpoint, $params = [ ]): \stdClass |
|
43 | 43 | { |
44 | 44 | |
45 | 45 | $headers = $this->headers(); |
@@ -53,7 +53,7 @@ discard block |
||
53 | 53 | private function headers(): array |
54 | 54 | { |
55 | 55 | |
56 | - $headers = []; |
|
56 | + $headers = [ ]; |
|
57 | 57 | if ($this->getAccessToken() !== null) { |
58 | 58 | $headers[ 'Authorization' ] = 'Bearer ' . $this->getAccessToken(); |
59 | 59 | } |
@@ -110,7 +110,7 @@ discard block |
||
110 | 110 | * @throws InoreaderException |
111 | 111 | * @return \stdClass |
112 | 112 | */ |
113 | - public function get(string $endpoint, $params = []): \stdClass |
|
113 | + public function get(string $endpoint, $params = [ ]): \stdClass |
|
114 | 114 | { |
115 | 115 | |
116 | 116 | $headers = $this->headers(); |
@@ -1,4 +1,4 @@ |
||
1 | -<?php declare(strict_types=1); |
|
1 | +<?php declare(strict_types = 1); |
|
2 | 2 | |
3 | 3 | |
4 | 4 | namespace ExileeD\Inoreader\Objects; |
@@ -1,5 +1,5 @@ |
||
1 | 1 | <?php |
2 | -declare(strict_types=1); |
|
2 | +declare(strict_types = 1); |
|
3 | 3 | /** |
4 | 4 | * @package inoreader-api |
5 | 5 | * |
@@ -1,4 +1,4 @@ discard block |
||
1 | -<?php declare(strict_types=1); |
|
1 | +<?php declare(strict_types = 1); |
|
2 | 2 | |
3 | 3 | |
4 | 4 | namespace ExileeD\Inoreader; |
@@ -222,12 +222,12 @@ discard block |
||
222 | 222 | public function tagsList($types = 1, $counts = 1): array |
223 | 223 | { |
224 | 224 | |
225 | - $response = $this->getClient()->get('tag/list', ['types' => $types, 'counts' => $counts]); |
|
225 | + $response = $this->getClient()->get('tag/list', [ 'types' => $types, 'counts' => $counts ]); |
|
226 | 226 | |
227 | - $result = []; |
|
227 | + $result = [ ]; |
|
228 | 228 | |
229 | 229 | foreach ($response->tags as $tag) { |
230 | - $result[] = new Tag($tag); |
|
230 | + $result[ ] = new Tag($tag); |
|
231 | 231 | } |
232 | 232 | |
233 | 233 | return $result; |
@@ -243,7 +243,7 @@ discard block |
||
243 | 243 | * @throws InoreaderException |
244 | 244 | * @return StreamContents |
245 | 245 | */ |
246 | - public function streamContents(array $params = []): StreamContents |
|
246 | + public function streamContents(array $params = [ ]): StreamContents |
|
247 | 247 | { |
248 | 248 | |
249 | 249 | $response = $this->getClient()->get('stream/contents', $params); |
@@ -262,7 +262,7 @@ discard block |
||
262 | 262 | * @throws InoreaderException |
263 | 263 | * @return ItemIds |
264 | 264 | */ |
265 | - public function itemsIds(array $params = []): ItemIds |
|
265 | + public function itemsIds(array $params = [ ]): ItemIds |
|
266 | 266 | { |
267 | 267 | |
268 | 268 | $response = $this->getClient()->get('stream/items/ids', $params); |