-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Remove .promise() calls from APIs called from new client (#857)
- Loading branch information
Showing
7 changed files
with
76 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"aws-sdk-js-codemod": patch | ||
--- | ||
|
||
Remove .promise() calls from APIs called from new client |
3 changes: 3 additions & 0 deletions
3
src/transforms/v2-to-v3/__fixtures__/api-promise/global-client-creation.input.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
import AWS from "aws-sdk"; | ||
|
||
const data = await new AWS.DynamoDB().listTables().promise(); |
3 changes: 3 additions & 0 deletions
3
src/transforms/v2-to-v3/__fixtures__/api-promise/global-client-creation.output.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
import { DynamoDB } from "@aws-sdk/client-dynamodb"; | ||
|
||
const data = await new DynamoDB().listTables(); |
3 changes: 3 additions & 0 deletions
3
src/transforms/v2-to-v3/__fixtures__/api-promise/service-client-creation.input.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
import { DynamoDB } from "aws-sdk"; | ||
|
||
const data = await new DynamoDB().listTables().promise(); |
3 changes: 3 additions & 0 deletions
3
src/transforms/v2-to-v3/__fixtures__/api-promise/service-client-creation.output.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
import { DynamoDB } from "@aws-sdk/client-dynamodb"; | ||
|
||
const data = await new DynamoDB().listTables(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters