@@ -18,7 +18,7 @@ discard block |
||
18 | 18 | { |
19 | 19 | $this->accessToken = $accessToken; |
20 | 20 | $this->apiUrl = $apiUrl; |
21 | - $this->client = new Client(['base_uri' => $this->apiUrl . '/']); |
|
21 | + $this->client = new Client(['base_uri' => $this->apiUrl.'/']); |
|
22 | 22 | } |
23 | 23 | |
24 | 24 | public function getAccessToken(): string |
@@ -39,12 +39,12 @@ discard block |
||
39 | 39 | public function setApiUrl(string $apiUrl) |
40 | 40 | { |
41 | 41 | $this->apiUrl = $apiUrl; |
42 | - $this->client = new Client(['base_uri' => $apiUrl . '/']); |
|
42 | + $this->client = new Client(['base_uri' => $apiUrl.'/']); |
|
43 | 43 | } |
44 | 44 | |
45 | 45 | private function handleBadResponse(ResponseInterface $response) |
46 | 46 | { |
47 | - $body = (string) $response->getBody(); |
|
47 | + $body = (string)$response->getBody(); |
|
48 | 48 | $json = \GuzzleHttp\json_decode($body, true); |
49 | 49 | ErrorHandler::error($json); |
50 | 50 | } |
@@ -14,7 +14,7 @@ |
||
14 | 14 | { |
15 | 15 | public static function error(array $error) |
16 | 16 | { |
17 | - switch($error['error']) { |
|
17 | + switch ($error['error']) { |
|
18 | 18 | case 'invalid_request': throw new InvalidRequestException($error['message']); |
19 | 19 | case 'account_banned': throw new AccountBannedException($error['message']); |
20 | 20 | case 'account_deleted': throw new AccountDeletedException($error['message']); |