Skip to content

Commit 428ca23

Browse files
committed
Fix keyword fetching for autocomplete when show tables fails
1 parent fae47c6 commit 428ca23

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

fetchKeywords.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ const replKeywords = new Set([
1818
]);
1919

2020
export default async function fetchKeywords(rdsDataClient: RDSDataClient, resourceArn: string, secretArn: string, database?: string): Promise<Keywords> {
21-
let records;
21+
let records: Field[][] | undefined;
2222

2323
try {
2424
({ records } = await rdsDataClient.send(
@@ -44,6 +44,8 @@ export default async function fetchKeywords(rdsDataClient: RDSDataClient, resour
4444
const objectDotNames: Set<string> = new Set();
4545

4646
if (database) {
47+
let records: Field[][] | undefined;
48+
4749
try {
4850
({ records } = await rdsDataClient.send(
4951
new ExecuteStatementCommand({

0 commit comments

Comments
 (0)