diff --git a/lib/Imgur/Auth/OAuth2.php b/lib/Imgur/Auth/OAuth2.php index 97179f3..d6142db 100644 --- a/lib/Imgur/Auth/OAuth2.php +++ b/lib/Imgur/Auth/OAuth2.php @@ -87,8 +87,6 @@ public function getAuthenticationURL(string $responseType = 'code', string $stat /** * Exchanges a code/pin for an access token. - * - * @param string $requestType */ public function requestAccessToken(string $code, string $requestType = null): array { @@ -166,8 +164,6 @@ public function refreshToken(): array /** * Stores the access token, refresh token and expiration date. * - * @param array $token - * * @throws AuthException */ public function setAccessToken(array $token = null): void diff --git a/lib/Imgur/Client.php b/lib/Imgur/Client.php index be02057..cb025a0 100644 --- a/lib/Imgur/Client.php +++ b/lib/Imgur/Client.php @@ -49,8 +49,6 @@ public function __construct(AuthInterface $authenticationClient = null, HttpClie } /** - * @param PagerInterface $pager - * * @throws InvalidArgumentException */ public function api(string $name, PagerInterface $pager = null): AbstractApi @@ -86,8 +84,6 @@ public function setHttpClient(HttpClientInterface $httpClient): void /** * @throws InvalidArgumentException - * - * @return string */ public function getOption(string $name): ?string { @@ -99,8 +95,6 @@ public function getOption(string $name): ?string } /** - * @param mixed $value - * * @throws InvalidArgumentException */ public function setOption(string $name, $value): void @@ -130,8 +124,6 @@ public function getAuthenticationClient(): AuthInterface /** * Proxy method for the authentication objects URL building method. - * - * @param string $state */ public function getAuthenticationUrl(string $responseType = 'code', string $state = null): string { @@ -148,8 +140,6 @@ public function requestAccessToken(string $code, string $responseType = 'code'): /** * Proxy method for retrieving the access token. - * - * @return array */ public function getAccessToken(): ?array { diff --git a/lib/Imgur/HttpClient/HttpClient.php b/lib/Imgur/HttpClient/HttpClient.php index 4c8c71b..f9f0daa 100644 --- a/lib/Imgur/HttpClient/HttpClient.php +++ b/lib/Imgur/HttpClient/HttpClient.php @@ -56,41 +56,26 @@ public function __construct(array $options = [], ClientInterface $client = null, ]); } - /** - * {@inheritdoc} - */ public function get($url, array $parameters = []): ResponseInterface { return $this->performRequest($url, $parameters, 'GET'); } - /** - * {@inheritdoc} - */ public function delete($url, array $parameters = []): ResponseInterface { return $this->performRequest($url, $parameters, 'DELETE'); } - /** - * {@inheritdoc} - */ public function post($url, array $parameters = []): ResponseInterface { return $this->performRequest($url, $parameters, 'POST'); } - /** - * {@inheritdoc} - */ public function put($url, array $parameters = []): ResponseInterface { return $this->performRequest($url, $parameters, 'PUT'); } - /** - * {@inheritdoc} - */ public function performRequest($url, $parameters, $httpMethod = 'GET'): ResponseInterface { $options = [ @@ -117,9 +102,6 @@ public function performRequest($url, $parameters, $httpMethod = 'GET'): Response return $this->client->request($httpMethod, $url, $options); } - /** - * {@inheritdoc} - */ public function parseResponse(ResponseInterface $response): array { $responseBody = [ @@ -134,9 +116,6 @@ public function parseResponse(ResponseInterface $response): array return $responseBody['data']; } - /** - * {@inheritdoc} - */ public function addAuthMiddleware($token, string $clientId): void { $this->stack->push(Middleware::mapRequest(function (RequestInterface $request) use ($token, $clientId) { diff --git a/lib/Imgur/Middleware/ErrorMiddleware.php b/lib/Imgur/Middleware/ErrorMiddleware.php index 48716ab..85d2c43 100644 --- a/lib/Imgur/Middleware/ErrorMiddleware.php +++ b/lib/Imgur/Middleware/ErrorMiddleware.php @@ -53,7 +53,7 @@ public function checkError(ResponseInterface $response): ?ResponseInterface return $response; } - //check if any limit was hit + // check if any limit was hit $this->checkUserRateLimit($response); $this->checkClientRateLimit($response); $this->checkPostRateLimit($response); diff --git a/lib/Imgur/Pager/BasicPager.php b/lib/Imgur/Pager/BasicPager.php index c81d405..37e61b9 100644 --- a/lib/Imgur/Pager/BasicPager.php +++ b/lib/Imgur/Pager/BasicPager.php @@ -38,8 +38,6 @@ public function getResultsPerPage(): int /** * Set the page number to be retrieved. - * - * @return BasicPager */ public function setPage(int $page): self { @@ -50,8 +48,6 @@ public function setPage(int $page): self /** * Set the number of results per page. - * - * @return BasicPager */ public function setResultsPerPage(int $resultsPerPage): self { diff --git a/tests/Api/ApiTestCase.php b/tests/Api/ApiTestCase.php index 894cc29..e14b15a 100644 --- a/tests/Api/ApiTestCase.php +++ b/tests/Api/ApiTestCase.php @@ -90,8 +90,6 @@ protected function getApiTopicMock() /** * @param class-string $class - * - * @return mixed */ private function getApiMock($class) {