Skip to content

Commit da8d32c

Browse files
committed
Return object from findCommonResultSetNames
1 parent f3a0ad2 commit da8d32c

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

extensions/ql-vscode/src/compare/compare-view.ts

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -83,16 +83,16 @@ export class CompareView extends AbstractWebview<
8383
panel.reveal(undefined, true);
8484

8585
await this.waitForPanelLoaded();
86-
const [
86+
const {
8787
commonResultSetNames,
88-
currentResultSetName,
88+
currentResultSetDisplayName,
8989
fromResultSet,
9090
toResultSet,
91-
] = await this.findCommonResultSetNames(
91+
} = await this.findCommonResultSetNames(
9292
this.comparePair,
9393
selectedResultSetName,
9494
);
95-
if (currentResultSetName) {
95+
if (currentResultSetDisplayName) {
9696
let rows: QueryCompareResult | undefined;
9797
let message: string | undefined;
9898
try {
@@ -120,7 +120,7 @@ export class CompareView extends AbstractWebview<
120120
},
121121
columns: fromResultSet.columns,
122122
commonResultSetNames,
123-
currentResultSetName,
123+
currentResultSetName: currentResultSetDisplayName,
124124
rows,
125125
message,
126126
databaseUri: to.initialInfo.databaseInfo.databaseUri,
@@ -193,7 +193,7 @@ export class CompareView extends AbstractWebview<
193193
private async findCommonResultSetNames(
194194
{ from, fromSchemas, to, toSchemas }: ComparePair,
195195
selectedResultSetName: string | undefined,
196-
): Promise<[string[], string, DecodedBqrsChunk, DecodedBqrsChunk]> {
196+
) {
197197
const {
198198
commonResultSetNames,
199199
currentResultSetDisplayName,
@@ -211,12 +211,12 @@ export class CompareView extends AbstractWebview<
211211
toResultSetName,
212212
to.completedQuery.query.resultsPaths.resultsPath,
213213
);
214-
return [
214+
return {
215215
commonResultSetNames,
216216
currentResultSetDisplayName,
217217
fromResultSet,
218218
toResultSet,
219-
];
219+
};
220220
}
221221

222222
private async changeTable(newResultSetName: string) {

0 commit comments

Comments
 (0)