Skip to content

Commit 271d334

Browse files
authored
Sort exceptions alphabetically (#1875)
1 parent 35672b8 commit 271d334

File tree

2 files changed

+18
-14
lines changed

2 files changed

+18
-14
lines changed

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22

33
## NOT RELEASED
44

5+
### Changed
6+
7+
- Sort exception alphabetically.
8+
59
## 1.1.3
610

711
### Changed

src/IotDataClient.php

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -43,26 +43,26 @@ class IotDataClient extends AbstractApi
4343
* '@region'?: string|null,
4444
* }|GetThingShadowRequest $input
4545
*
46+
* @throws InternalFailureException
4647
* @throws InvalidRequestException
48+
* @throws MethodNotAllowedException
4749
* @throws ResourceNotFoundException
50+
* @throws ServiceUnavailableException
4851
* @throws ThrottlingException
4952
* @throws UnauthorizedException
50-
* @throws ServiceUnavailableException
51-
* @throws InternalFailureException
52-
* @throws MethodNotAllowedException
5353
* @throws UnsupportedDocumentEncodingException
5454
*/
5555
public function getThingShadow($input): GetThingShadowResponse
5656
{
5757
$input = GetThingShadowRequest::create($input);
5858
$response = $this->getResponse($input->request(), new RequestContext(['operation' => 'GetThingShadow', 'region' => $input->getRegion(), 'exceptionMapping' => [
59+
'InternalFailureException' => InternalFailureException::class,
5960
'InvalidRequestException' => InvalidRequestException::class,
61+
'MethodNotAllowedException' => MethodNotAllowedException::class,
6062
'ResourceNotFoundException' => ResourceNotFoundException::class,
63+
'ServiceUnavailableException' => ServiceUnavailableException::class,
6164
'ThrottlingException' => ThrottlingException::class,
6265
'UnauthorizedException' => UnauthorizedException::class,
63-
'ServiceUnavailableException' => ServiceUnavailableException::class,
64-
'InternalFailureException' => InternalFailureException::class,
65-
'MethodNotAllowedException' => MethodNotAllowedException::class,
6666
'UnsupportedDocumentEncodingException' => UnsupportedDocumentEncodingException::class,
6767
]]));
6868

@@ -90,27 +90,27 @@ public function getThingShadow($input): GetThingShadowResponse
9090
* }|UpdateThingShadowRequest $input
9191
*
9292
* @throws ConflictException
93-
* @throws RequestEntityTooLargeException
93+
* @throws InternalFailureException
9494
* @throws InvalidRequestException
95+
* @throws MethodNotAllowedException
96+
* @throws RequestEntityTooLargeException
97+
* @throws ServiceUnavailableException
9598
* @throws ThrottlingException
9699
* @throws UnauthorizedException
97-
* @throws ServiceUnavailableException
98-
* @throws InternalFailureException
99-
* @throws MethodNotAllowedException
100100
* @throws UnsupportedDocumentEncodingException
101101
*/
102102
public function updateThingShadow($input): UpdateThingShadowResponse
103103
{
104104
$input = UpdateThingShadowRequest::create($input);
105105
$response = $this->getResponse($input->request(), new RequestContext(['operation' => 'UpdateThingShadow', 'region' => $input->getRegion(), 'exceptionMapping' => [
106106
'ConflictException' => ConflictException::class,
107-
'RequestEntityTooLargeException' => RequestEntityTooLargeException::class,
107+
'InternalFailureException' => InternalFailureException::class,
108108
'InvalidRequestException' => InvalidRequestException::class,
109+
'MethodNotAllowedException' => MethodNotAllowedException::class,
110+
'RequestEntityTooLargeException' => RequestEntityTooLargeException::class,
111+
'ServiceUnavailableException' => ServiceUnavailableException::class,
109112
'ThrottlingException' => ThrottlingException::class,
110113
'UnauthorizedException' => UnauthorizedException::class,
111-
'ServiceUnavailableException' => ServiceUnavailableException::class,
112-
'InternalFailureException' => InternalFailureException::class,
113-
'MethodNotAllowedException' => MethodNotAllowedException::class,
114114
'UnsupportedDocumentEncodingException' => UnsupportedDocumentEncodingException::class,
115115
]]));
116116

0 commit comments

Comments
 (0)