Skip to content

Commit 44b46ba

Browse files
authored
Make sure we dont throw exception twice (#173)
* Make sure we dont throw exception twice This will fix #171 * Fixes * Return isResolved in the info
1 parent 58a6860 commit 44b46ba

File tree

4 files changed

+1
-28
lines changed

4 files changed

+1
-28
lines changed

Result/AddLayerVersionPermissionResponse.php

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -18,14 +18,6 @@ class AddLayerVersionPermissionResponse extends Result
1818
*/
1919
private $RevisionId;
2020

21-
/**
22-
* Ensure current request is resolved and right exception is thrown.
23-
*/
24-
public function __destruct()
25-
{
26-
$this->resolve();
27-
}
28-
2921
public function getRevisionId(): ?string
3022
{
3123
$this->initialize();

Result/InvocationResponse.php

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -37,14 +37,6 @@ class InvocationResponse extends Result
3737
*/
3838
private $ExecutedVersion;
3939

40-
/**
41-
* Ensure current request is resolved and right exception is thrown.
42-
*/
43-
public function __destruct()
44-
{
45-
$this->resolve();
46-
}
47-
4840
public function getExecutedVersion(): ?string
4941
{
5042
$this->initialize();

Result/ListLayerVersionsResponse.php

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,16 +25,13 @@ class ListLayerVersionsResponse extends Result implements \IteratorAggregate
2525
*/
2626
private $prefetch = [];
2727

28-
/**
29-
* Ensure current request is resolved and right exception is thrown.
30-
*/
3128
public function __destruct()
3229
{
3330
while (!empty($this->prefetch)) {
3431
array_shift($this->prefetch)->cancel();
3532
}
3633

37-
$this->resolve();
34+
parent::__destruct();
3835
}
3936

4037
/**

Result/PublishLayerVersionResponse.php

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -50,14 +50,6 @@ class PublishLayerVersionResponse extends Result
5050
*/
5151
private $LicenseInfo;
5252

53-
/**
54-
* Ensure current request is resolved and right exception is thrown.
55-
*/
56-
public function __destruct()
57-
{
58-
$this->resolve();
59-
}
60-
6153
/**
6254
* @return string[]
6355
*/

0 commit comments

Comments
 (0)